/* =========================================================
   yeemanews.com: "bộ tem đời sống"
   Mỗi chuyên mục là một loạt tem có màu mực riêng (nav, nhãn, tên khối, ô tem khi bài chưa có ảnh).
   Nền giấy trắng, chữ mực xanh đen, con dấu bưu điện đỏ ở đầu trang, dải răng cưa mở đầu mỗi khối.
   Không hộp, không bóng: các bài ngăn nhau bằng kẻ mảnh. Tiêu đề Bricolage Grotesque, chữ đọc Literata.
   ========================================================= */
:root {
  --paper: #fff; --tint: #f3f4f8; --text: #1b2236; --text-2: #3d4459; --muted: #5d6478; --rule: #dde0e8;
  --red: #c30d10; --red-deep: #9d0a0d;
  --head: "Bricolage Grotesque", system-ui, -apple-system, "Segoe UI", sans-serif;
  --read: "Literata", Georgia, "Times New Roman", serif;
  --ink: var(--red);
}
/* Màu mực của 6 loạt tem; chữ trắng trên các màu này đạt ≥ 4.5:1 */
.qwd-ink-0 { --ink: #0f7a5a; }
.qwd-ink-1 { --ink: #2b49a6; }
.qwd-ink-2 { --ink: #95580a; }
.qwd-ink-3 { --ink: #86295f; }
.qwd-ink-4 { --ink: #0b6b78; }
.qwd-ink-5 { --ink: #b23c1c; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--text); font: 16px/1.6 var(--read); -webkit-font-smoothing: antialiased; overflow-x: clip; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--red); }
button, input { font: inherit; }
::selection { background: #f6d5d5; color: var(--text); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.qwd-wrap { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.qwd-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.qwd-skip { position: absolute; left: -999px; top: 0; z-index: 99; background: var(--text); color: #fff; padding: 12px 16px; }
.qwd-skip:focus { left: 8px; color: #fff; }
.qwd-empty { padding: 48px 0; text-align: center; color: var(--muted); }

/* Dải răng cưa: hàng lỗ tròn như mép tờ tem, dùng dưới đầu trang và mở đầu mỗi khối */
.qwd-perf, .qwd-sec::before { display: block; height: 8px; background: radial-gradient(circle, var(--rule) 2.6px, transparent 3.1px) 0 50% / 11px 8px repeat-x; }

/* ---------- Đầu trang ---------- */
.qwd-bar { background: var(--paper); }
.qwd-bar-in { position: relative; display: flex; align-items: center; gap: 18px; min-height: 104px; }
.qwd-logo { flex: none; font: 800 44px/1 var(--head); letter-spacing: -.035em; color: var(--text); }
.qwd-logo:hover { color: var(--text); }
.qwd-logo img { height: 52px; width: auto; }
.qwd-postmark { flex: none; width: 84px; height: 84px; color: var(--red); transform: rotate(-12deg); }
.qwd-pm-ring { font: 700 9.5px var(--head); fill: currentColor; }
.qwd-pm-day { font: 800 15px var(--head); fill: currentColor; }
.qwd-pm-year { font: 600 10px var(--head); fill: currentColor; }
.qwd-search { display: flex; align-items: center; flex: none; width: 280px; height: 44px; margin-left: auto; border-bottom: 2px solid var(--text); }
.qwd-search:focus-within { border-color: var(--red); }
.qwd-search input { flex: 1; min-width: 0; height: 100%; padding: 0 4px; border: 0; background: transparent; color: var(--text); font: 400 15px var(--read); outline: 0; }
.qwd-search input::placeholder { color: var(--muted); }
.qwd-search button { display: grid; place-items: center; width: 44px; height: 100%; border: 0; background: transparent; color: var(--text); cursor: pointer; }
.qwd-search button:hover { color: var(--red); }
.qwd-burger, .qwd-find { display: none; }
.qwd-burger > summary, .qwd-find > summary { display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; cursor: pointer; list-style: none; color: var(--text); }
.qwd-burger > summary::-webkit-details-marker, .qwd-find > summary::-webkit-details-marker { display: none; }
.qwd-burger-icon, .qwd-burger-icon::before, .qwd-burger-icon::after { display: block; width: 20px; height: 2px; background: currentColor; }
.qwd-burger-icon { position: relative; }
.qwd-burger-icon::before, .qwd-burger-icon::after { content: ""; position: absolute; left: 0; }
.qwd-burger-icon::before { top: -6px; }
.qwd-burger-icon::after { top: 6px; }
.qwd-burger[open] .qwd-burger-icon { background: transparent; }
.qwd-burger[open] .qwd-burger-icon::before { top: 0; transform: rotate(45deg); }
.qwd-burger[open] .qwd-burger-icon::after { top: 0; transform: rotate(-45deg); }
.qwd-drawer { position: absolute; left: 0; right: 0; top: 100%; z-index: 70; max-height: 75vh; overflow-y: auto; background: var(--paper); border-bottom: 1px solid var(--rule); box-shadow: 0 18px 30px -18px rgba(27, 34, 54, .35); }
.qwd-drawer ul { list-style: none; margin: 0; padding: 4px 16px 12px; }
.qwd-drawer a { display: flex; align-items: center; gap: 12px; min-height: 50px; border-bottom: 1px solid var(--rule); font: 600 16px var(--head); color: var(--text); }
.qwd-drawer [aria-current] { color: var(--red); }
.qwd-find-box { display: flex; gap: 8px; }
.qwd-find > .qwd-find-box { position: absolute; left: 12px; right: 12px; top: 100%; z-index: 70; padding: 12px; background: var(--paper); border: 1px solid var(--rule); box-shadow: 0 18px 30px -18px rgba(27, 34, 54, .35); }
.qwd-find-box input[type=search] { flex: 1; min-width: 0; height: 44px; padding: 0 12px; border: 1px solid var(--rule); background: var(--paper); color: var(--text); font-size: 16px; }
.qwd-find-box button { height: 44px; padding: 0 20px; border: 0; background: var(--text); color: #fff; font: 600 15px var(--head); cursor: pointer; }
.qwd-find-box button:hover { background: var(--red); }

/* ---------- Nav: mỗi chuyên mục một ô màu mực ---------- */
.qwd-nav { position: sticky; top: 0; z-index: 60; background: var(--paper); border-bottom: 1px solid var(--rule); }
.qwd-nav-list { display: flex; list-style: none; margin-top: 0; margin-bottom: 0; overflow-x: auto; scrollbar-width: none; }
.qwd-nav-list::-webkit-scrollbar { display: none; }
.qwd-nav-list a { position: relative; display: flex; align-items: center; gap: 8px; height: 50px; padding: 0 12px; font: 600 15px var(--head); color: var(--text-2); white-space: nowrap; }
.qwd-nav-list a:hover { color: var(--ink); }
.qwd-nav-list [aria-current] { color: var(--ink); }
.qwd-nav-list [aria-current]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 3px; background: var(--ink); }
.qwd-chip { flex: none; width: 10px; height: 10px; background: var(--ink); }
.qwd-nav-home { padding-left: 0 !important; color: var(--text) !important; }
.qwd-nav-home:hover { color: var(--red) !important; }

/* ---------- Phần tử chung ---------- */
.qwd-kick { align-self: flex-start; display: inline-flex; align-items: center; gap: 7px; font: 600 13.5px/1.3 var(--head); color: var(--ink); }
.qwd-kick::before { content: ""; width: 8px; height: 8px; background: var(--ink); }
.qwd-kick:hover { color: var(--text); }
.qwd-date { font: 400 13px var(--head); color: var(--muted); }

/* Mở đầu khối */
.qwd-sec { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin: 0 0 22px; }
.qwd-sec::before { content: ""; flex: 0 0 100%; margin-bottom: 18px; }
.qwd-sec-title { margin: 0; font: 800 32px/1.1 var(--head); letter-spacing: -.025em; color: var(--ink); }
.qwd-sec:not([class*="qwd-ink-"]) .qwd-sec-title { color: var(--text); }
.qwd-sec-title a { color: inherit; }
.qwd-sec-title a:hover { color: var(--text); }
.qwd-sec-note { font: 400 15px var(--read); color: var(--muted); }
.qwd-sec-more { display: inline-flex; align-items: center; min-height: 44px; margin-left: auto; font: 600 14.5px var(--head); color: var(--text); text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--ink); text-underline-offset: 5px; }
.qwd-sec-more:hover { color: var(--ink); }

/* Bài chưa có ảnh: nền nhạt màu mực, giữa là một con tem nhỏ (viền răng cưa chấm, lõi màu mực nhạt), không chữ.
   Kích thước tem theo chiều cao khung nên ô lớn hay nhỏ đều cân */
.qwd-stamp { display: grid; place-items: center; width: 100%; height: 100%; background: color-mix(in srgb, var(--ink) 7%, #fff); }
.qwd-stamp::before { content: ""; height: 38%; aspect-ratio: 4 / 5; border: 2px dotted color-mix(in srgb, var(--ink) 55%, #fff); background: color-mix(in srgb, var(--ink) 16%, #fff) content-box; padding: 5px; transform: rotate(-4deg); }

/* ---------- Trang chủ ---------- */
.qwd-intro { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; padding: 22px 0 0; }
.qwd-intro-title { margin: 0; font: 800 20px/1.3 var(--head); letter-spacing: -.01em; color: var(--red); }
.qwd-intro-desc { margin: 0; font: 400 15.5px/1.5 var(--read); color: var(--text-2); }
.qwd-top { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 40px; margin-top: 24px; }
.qwd-top-list { border-left: 1px solid var(--rule); padding-left: 32px; }
.qwd-top-name { margin: 0 0 6px; font: 800 20px/1.2 var(--head); color: var(--red); }
.qwd-top-list .qwd-side:last-child { border-bottom: 0; }

.qwd-strip { display: grid; gap: 28px; margin-top: 36px; }
.qwd-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.qwd-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.qwd-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* Hàng thẻ ngăn bằng kẻ dọc */
.qwd-ruled { gap: 0; border-top: 1px solid var(--rule); padding-top: 24px; }
.qwd-ruled > * { padding: 0 20px; border-left: 1px solid var(--rule); }
.qwd-ruled > :first-child { padding-left: 0; border-left: 0; }
.qwd-ruled > :last-child { padding-right: 0; }
.qwd-blk { margin-top: 64px; }
.qwd-blk .qwd-strip { margin-top: 0; }

/* ---------- Thẻ dọc (không khung) ---------- */
.qwd-cover { display: flex; flex-direction: column; min-width: 0; }
.qwd-cover-pic { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--tint); }
.qwd-cover-pic img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.16, 1, .3, 1); }
.qwd-cover:hover .qwd-cover-pic img { transform: scale(1.03); }
.qwd-cover-body { display: flex; flex-direction: column; gap: 8px; padding-top: 14px; }
.qwd-cover-title { margin: 0; font: 700 18px/1.32 var(--head); letter-spacing: -.012em; text-wrap: balance; }
.qwd-cover-title a { color: var(--text); }
.qwd-cover-title a:hover { color: var(--ink); }
.qwd-cover-sapo { display: -webkit-box; margin: 0; overflow: hidden; -webkit-line-clamp: 3; -webkit-box-orient: vertical; font-size: 15px; line-height: 1.6; color: var(--muted); }
/* Tin lớn trang chủ */
.qwd-cover-lead .qwd-cover-body { gap: 12px; padding-top: 20px; }
.qwd-cover-lead .qwd-cover-title { font-size: clamp(30px, 3.2vw, 44px); font-weight: 800; line-height: 1.1; letter-spacing: -.03em; text-wrap: balance; }
.qwd-cover-lead .qwd-cover-sapo { font-size: 17.5px; line-height: 1.65; color: var(--text-2); max-width: 62ch; }
.qwd-cover-lead .qwd-cover-pic:has(.qwd-stamp) { aspect-ratio: 16 / 8; }
/* Tin đầu khối lead-list */
.qwd-cover-wide .qwd-cover-pic:has(.qwd-stamp) { aspect-ratio: 16 / 8; }
.qwd-cover-wide .qwd-cover-title { font-size: 26px; font-weight: 800; line-height: 1.18; letter-spacing: -.022em; }
.qwd-cover-wide .qwd-cover-sapo { font-size: 16px; color: var(--text-2); }
/* Tin đầu trang chuyên mục: ảnh trái, chữ phải */
.qwd-cover-lg { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 36px; align-items: center; }
.qwd-cover-lg .qwd-cover-body { gap: 14px; padding-top: 0; }
.qwd-cover-lg .qwd-cover-title { font-size: clamp(28px, 2.8vw, 38px); font-weight: 800; line-height: 1.12; letter-spacing: -.028em; text-wrap: balance; }
.qwd-cover-lg .qwd-cover-sapo { font-size: 17px; -webkit-line-clamp: 4; color: var(--text-2); }

/* ---------- Khối chuyên mục ---------- */
.qwd-leadlist { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 40px; }
.qwd-leadlist-side { min-width: 0; border-left: 1px solid var(--rule); padding-left: 32px; }
.qwd-leadlist-side .qwd-side:first-child { padding-top: 0; }
.qwd-leadlist-side .qwd-side:last-child { border-bottom: 0; }
.qwd-scroller { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 28px) / 4); gap: 28px; overflow-x: auto; padding-bottom: 12px; scroll-snap-type: x mandatory; scrollbar-width: thin; scrollbar-color: var(--rule) transparent; }
.qwd-scroller > * { scroll-snap-align: start; }

/* ---------- Dòng gọn ---------- */
.qwd-side { display: grid; grid-template-columns: minmax(0, 1fr) 112px; gap: 16px; align-items: start; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.qwd-side-pic { order: 2; display: block; aspect-ratio: 16 / 11; overflow: hidden; background: var(--tint); }
.qwd-side-pic img { width: 100%; height: 100%; object-fit: cover; }
.qwd-side-body { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.qwd-side-title { display: -webkit-box; margin: 0; overflow: hidden; -webkit-line-clamp: 3; -webkit-box-orient: vertical; font: 700 16.5px/1.35 var(--head); letter-spacing: -.01em; text-wrap: balance; }
.qwd-side-title a { color: var(--text); }
.qwd-side-title a:hover { color: var(--ink); }

/* ---------- Thẻ ngang (tag, tìm kiếm, tác giả) ---------- */
.qwd-row { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 24px; padding: 22px 0; border-bottom: 1px solid var(--rule); }
.qwd-row:first-child { padding-top: 0; }
.qwd-row-text { grid-template-columns: minmax(0, 1fr); }
.qwd-row-pic { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--tint); align-self: start; }
.qwd-row-pic img { width: 100%; height: 100%; object-fit: cover; }
.qwd-row-body { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.qwd-row-title { margin: 0; font: 700 21px/1.3 var(--head); letter-spacing: -.015em; }
.qwd-row-title a { color: var(--text); }
.qwd-row-title a:hover { color: var(--ink); }
.qwd-row-sapo { display: -webkit-box; margin: 0; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; font-size: 15.5px; color: var(--muted); }

/* ---------- Breadcrumb, đầu trang chuyên mục ---------- */
.core-breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; min-height: 44px; margin: 16px 0 4px; font: 400 14px var(--head); color: var(--muted); }
.core-breadcrumb a { color: var(--muted); }
.core-breadcrumb a:hover { color: var(--red); }
.core-breadcrumb [aria-current] { color: var(--text-2); }
.qwd-pagehead { margin: 8px 0 32px; }
.qwd-pagehead-title { margin: 0; font: 800 clamp(34px, 4.4vw, 56px)/1.05 var(--head); letter-spacing: -.035em; color: var(--red); text-wrap: balance; }
.qwd-pagehead-pre { color: var(--text); margin-right: 4px; }
.qwd-pagehead-desc { margin: 14px 0 0; max-width: 66ch; font-size: 17px; line-height: 1.6; color: var(--text-2); }
.qwd-narrow { max-width: 860px; margin-left: auto; margin-right: auto; }
.qwd-catlead { padding-bottom: 32px; border-bottom: 1px solid var(--rule); }
.qwd-catlead + .qwd-strip { margin-top: 32px; }

/* Phân trang của CMS (ul.pagination > li[.active|.disabled] > a, có li lồng thừa). Chỉ 1 trang thì ẩn cả cụm */
.core-pagination { margin-top: 44px; }
.core-pagination .limit, .core-pagination select, .core-pagination .disabled { display: none; }
.core-pagination ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.core-pagination li { display: contents; }
.core-pagination a { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 12px; border: 1px solid var(--rule); font: 600 15px var(--head); color: var(--text-2); cursor: pointer; }
.core-pagination a:hover { border-color: var(--text); color: var(--text); }
.core-pagination .active > a { background: var(--text); border-color: var(--text); color: #fff; }
.core-pagination:not(:has(li:not(.disabled):not(.active) a)) { display: none; }

/* ---------- Bài viết ---------- */
.qwd-two { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 56px; align-items: start; }
.qwd-art { min-width: 0; padding-top: 8px; }
.qwd-art > .qwd-kick { font-size: 15px; }
.qwd-art-title { margin: 14px 0 18px; max-width: 22ch; font: 800 clamp(32px, 3.6vw, 48px)/1.1 var(--head); letter-spacing: -.032em; text-wrap: balance; }
.qwd-art-meta { display: flex; flex-wrap: wrap; gap: 4px 22px; margin: 0 0 30px; padding: 14px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); font: 400 14px var(--head); color: var(--muted); }
/* Ảnh đại diện đầu bài (_core/article-hero.tpl): khung 16:9 giữ chỗ trước khi ảnh tải */
.qwd-hero { margin: 0 0 28px; aspect-ratio: 16 / 9; overflow: hidden; background: #eee; }
.qwd-hero img { display: block; width: 100%; height: 100%; object-fit: cover; }
.qwd-art-by, .qwd-art-by a { color: var(--text); font-weight: 600; }
.qwd-art-by a:hover { color: var(--red); }
.qwd-toc { max-width: 68ch; margin: 0 0 30px; background: var(--tint); }
.qwd-toc > summary { display: flex; align-items: center; min-height: 50px; padding: 0 20px; cursor: pointer; list-style: none; font: 700 16px var(--head); color: var(--text); }
.qwd-toc > summary::-webkit-details-marker { display: none; }
.qwd-toc > summary::after { content: ""; width: 8px; height: 8px; margin-left: auto; border: solid var(--text); border-width: 0 2px 2px 0; transform: rotate(45deg) translateY(-2px); }
.qwd-toc[open] > summary::after { transform: rotate(-135deg) translateY(-2px); }
.qwd-toc ol { margin: 0; padding: 0 20px 12px 40px; }
.qwd-toc li::marker { font: 600 14px var(--head); color: var(--muted); }
.qwd-toc a { display: flex; align-items: center; min-height: 40px; font: 400 15.5px/1.4 var(--head); color: var(--text-2); }
.qwd-toc a:hover { color: var(--red); }
.qwd-toc-l3 { margin-left: 16px; }
.qwd-text { max-width: 68ch; font-size: 18.5px; line-height: 1.78; color: #262c3f; overflow-wrap: break-word; }
.qwd-text > p:first-child { font-size: 20px; line-height: 1.65; color: var(--text); }
.qwd-text-plain > p:first-child { font-size: inherit; color: inherit; }
.qwd-text p { margin: 0 0 1.15em; }
.qwd-text h2 { margin: 1.9em 0 .55em; font: 800 27px/1.22 var(--head); letter-spacing: -.02em; color: var(--text); scroll-margin-top: 64px; }
.qwd-text h3 { margin: 1.6em 0 .5em; font: 700 21px/1.3 var(--head); color: var(--text); scroll-margin-top: 64px; }
.qwd-text a { color: var(--red-deep); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.qwd-text ul, .qwd-text ol { margin: 0 0 1.2em; padding-left: 1.3em; }
.qwd-text li { margin-bottom: .45em; }
.qwd-text li::marker { color: var(--red); }
.qwd-text img { margin: 1.4em auto; }
.qwd-text figure { margin: 1.8em 0; }
.qwd-text figure img { margin: 0 auto; }
.qwd-text figcaption { margin-top: 10px; font: 400 14px/1.5 var(--head); color: var(--muted); }
.qwd-text blockquote { margin: 1.8em 0; padding: 22px 26px; background: var(--tint); font-size: 19px; line-height: 1.65; color: var(--text); }
.qwd-text blockquote p:last-child { margin-bottom: 0; }
.qwd-text table { display: block; width: 100%; overflow-x: auto; margin: 0 0 1.2em; border-collapse: collapse; font: 400 15px/1.5 var(--head); font-variant-numeric: tabular-nums; }
.qwd-text th, .qwd-text td { padding: 9px 12px; border: 1px solid var(--rule); text-align: left; vertical-align: top; }
.qwd-text th { background: var(--tint); font-weight: 700; }
.qwd-rel { max-width: 68ch; margin-top: 34px; padding-top: 18px; border-top: 2px solid var(--text); }
.qwd-rel-name { margin: 0 0 4px; font: 800 18px var(--head); color: var(--text); }
.qwd-rel ul { list-style: none; margin: 0; padding: 0; }
.qwd-rel li + li { border-top: 1px solid var(--rule); }
.qwd-rel a { display: flex; align-items: center; min-height: 50px; padding: 6px 0; font: 700 17px/1.35 var(--head); color: var(--text); }
.qwd-rel a:hover { color: var(--red); }
.qwd-aside { position: sticky; top: 70px; min-width: 0; }
.qwd-box-title { margin: 0; padding-bottom: 6px; border-bottom: 2px solid var(--text); font: 800 20px/1.3 var(--head); }
.qwd-box .qwd-side:last-child { border-bottom: 0; }
.qwd-art-static { margin-bottom: 8px; }

/* ---------- Trang lỗi ---------- */
.qwd-lost { max-width: 640px; margin: 56px auto; text-align: center; }
.qwd-lost-code { margin: 0 0 8px; font: 800 96px/1 var(--head); letter-spacing: -.04em; color: var(--red); }
.qwd-lost .qwd-pagehead-desc { margin-inline: auto; }
.qwd-lost-find { max-width: 460px; margin: 24px auto 8px; }

/* ---------- Chân trang ---------- */
.qwd-foot { margin-top: 80px; background: var(--text); color: #c9cdda; font: 400 15px/1.6 var(--head); }
.qwd-foot::before { content: ""; display: block; height: 8px; background: radial-gradient(circle at 6px 0, var(--paper) 3.6px, transparent 4.1px) 0 0 / 12px 8px repeat-x; }
.qwd-foot-in { display: grid; grid-template-columns: minmax(0, 1.8fr) minmax(0, 1fr); gap: 48px; padding-top: 48px; padding-bottom: 36px; }
.qwd-foot-name { margin: 0 0 12px; font: 800 32px/1 var(--head); letter-spacing: -.03em; color: #fff; }
.qwd-foot-desc { margin: 0; max-width: 56ch; color: #aeb3c3; }
.qwd-foot-head { margin: 0 0 6px; font: 700 16px var(--head); color: #fff; }
.qwd-foot-links { list-style: none; margin: 0; padding: 0; }
.qwd-foot-links a { display: inline-flex; align-items: center; min-height: 40px; color: #c9cdda; }
.qwd-foot-links a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.qwd-foot-bottom { border-top: 1px solid rgba(255, 255, 255, .12); }
.qwd-foot-bottom p { margin: 0 auto; padding-top: 16px; padding-bottom: 18px; font-size: 13.5px; color: #9ba1b4; }

/* ---------- Màn vừa ---------- */
@media (max-width: 1024px) {
  .qwd-logo { font-size: 38px; }
  .qwd-search { width: 220px; }
  .qwd-top { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .qwd-top-list { border-left: 0; padding-left: 0; border-top: 2px solid var(--text); padding-top: 14px; }
  .qwd-cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .qwd-ruled { row-gap: 28px; }
  .qwd-ruled > :nth-child(odd) { padding-left: 0; border-left: 0; }
  .qwd-ruled > :nth-child(even) { padding-right: 0; }
  .qwd-leadlist { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .qwd-leadlist-side { border-left: 0; padding-left: 0; }
  .qwd-scroller { grid-auto-columns: calc((100% - 2 * 28px) / 2.6); }
  .qwd-two { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .qwd-aside { position: static; }
}

/* ---------- Điện thoại ---------- */
@media (max-width: 767px) {
  body { font-size: 15.5px; }
  .qwd-wrap { padding-left: 16px; padding-right: 16px; }
  .qwd-bar { position: sticky; top: 0; z-index: 60; border-bottom: 1px solid var(--rule); }
  .qwd-bar-in { justify-content: center; min-height: 56px; gap: 8px; }
  .qwd-logo { font-size: 27px; }
  .qwd-logo img { height: 34px; }
  .qwd-postmark { width: 40px; height: 40px; }
  .qwd-search { display: none; }
  .qwd-burger { display: block; position: absolute; left: 6px; top: 6px; }
  .qwd-find { display: block; position: absolute; right: 6px; top: 6px; }
  .qwd-burger[open], .qwd-find[open] { position: static; }
  .qwd-burger[open] > summary { position: absolute; left: 6px; top: 6px; }
  .qwd-find[open] > summary { position: absolute; right: 6px; top: 6px; }
  .qwd-perf, .qwd-nav { display: none; }
  .qwd-intro { display: block; padding-top: 18px; }
  .qwd-intro-title { font-size: 18px; }
  .qwd-intro-desc { margin-top: 2px; font-size: 14.5px; }
  .qwd-top { margin-top: 16px; gap: 22px; }
  .qwd-cover-lead .qwd-cover-title { font-size: 28px; }
  .qwd-cover-lead .qwd-cover-sapo { font-size: 16px; }
  .qwd-strip { gap: 22px 16px; margin-top: 28px; }
  .qwd-cols-3, .qwd-cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .qwd-ruled > * { padding: 0 8px; }
  .qwd-ruled > :nth-child(odd) { padding-left: 0; }
  .qwd-ruled > :nth-child(even) { padding-right: 0; }
  .qwd-strip > :last-child:nth-child(odd) { grid-column: 1 / -1; padding-right: 0; }
  .qwd-strip > :last-child:nth-child(odd) .qwd-cover-pic { aspect-ratio: 16 / 8; }
  .qwd-cover-body { padding-top: 10px; gap: 6px; }
  .qwd-cover-title { font-size: 16px; }
  .qwd-strip .qwd-cover-sapo { display: none; }
  .qwd-kick { font-size: 12.5px; }
  .qwd-blk { margin-top: 48px; }
  .qwd-sec { margin-bottom: 16px; }
  .qwd-sec::before { margin-bottom: 14px; }
  .qwd-sec-title { font-size: 26px; }
  .qwd-sec-note { font-size: 14px; }
  .qwd-cover-wide .qwd-cover-title { font-size: 22px; }
  .qwd-scroller { grid-auto-columns: 64%; gap: 16px; }
  .qwd-side { grid-template-columns: minmax(0, 1fr) 96px; gap: 12px; }
  .qwd-side-title { font-size: 15.5px; }
  .qwd-cover-lg { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .qwd-cover-lg .qwd-cover-body { padding-top: 14px; }
  .qwd-cover-lg .qwd-cover-title { font-size: 26px; }
  .qwd-row { grid-template-columns: minmax(0, 1fr) 112px; gap: 14px; padding: 16px 0; }
  .qwd-row-pic { order: 2; }
  .qwd-row-text { grid-template-columns: minmax(0, 1fr); }
  .qwd-row-title { font-size: 17px; }
  .qwd-row-sapo { display: none; }
  .qwd-row-text .qwd-row-sapo { display: -webkit-box; }
  .qwd-pagehead-title { font-size: 34px; }
  .qwd-pagehead-desc { font-size: 15.5px; }
  .qwd-art-title { font-size: 30px; }
  .qwd-art-meta { gap: 2px 16px; margin-bottom: 24px; }
  .qwd-text { font-size: 17.5px; line-height: 1.75; }
  .qwd-text > p:first-child { font-size: 18.5px; }
  .qwd-text h2 { font-size: 23px; }
  .qwd-text blockquote { padding: 18px; font-size: 17.5px; }
  .qwd-foot { margin-top: 56px; }
  .qwd-foot-in { grid-template-columns: minmax(0, 1fr); gap: 24px; padding-top: 36px; padding-bottom: 24px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
/* Trang chuyên mục: tên chuyên mục in màu mực của nó */
.qwd-pagehead[class*="qwd-ink-"] .qwd-pagehead-title { color: var(--ink); }
