/* Đặt lại mặc định trình duyệt */
html, body { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
img { max-width: 100%; }
[hidden] { display: none !important; }

/* Layout: two views. Home = hero search, category grid, latest cards. Listings (#danh-sach) = filter sidebar + result rows; on phones the sidebar becomes a bottom sheet. Detail (#tin-<id>) = content column + sticky contact card; on phones a fixed contact bar. Guides (#tin-tuc, #bai-<slug>) = magazine list + reading column with sticky table of contents. */
:root {
  --bg: #f3f6f5;
  --surface: #ffffff;
  --fg: #16231f;
  --muted: #5b6b66;
  --line: #dbe3e0;
  --accent: #0e6e5c;
  --accent-fg: #ffffff;
  --accent-soft: #dcefe9;
  --hot: #d9542f;
  --price: #b2401d;
  --hero: #0b3f35;
  --font-display: "Lexend", "Be Vietnam Pro", system-ui, sans-serif;
  --font-body: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 10px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1614; --surface: #17211e; --fg: #e5eeeb; --muted: #97a8a2; --line: #2a3733;
    --accent: #3fb69c; --accent-fg: #06201a; --accent-soft: #173a32; --hot: #f07a55; --price: #f39a7a; --hero: #0f2f29;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1614; --surface: #17211e; --fg: #e5eeeb; --muted: #97a8a2; --line: #2a3733;
  --accent: #3fb69c; --accent-fg: #06201a; --accent-soft: #173a32; --hot: #f07a55; --price: #f39a7a; --hero: #0f2f29;
  color-scheme: dark;
}
* { box-sizing: border-box; }
body { background: var(--bg); color: var(--fg); font-family: var(--font-body); font-size: 15px; line-height: 1.5; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--surface); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.wrap { max-width: 1180px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }

header.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; gap: 10px 24px; padding-block: 12px; }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--fg); }
.brand b { font-family: var(--font-display); font-size: 21px; font-weight: 700; letter-spacing: -0.02em; }
.brand b span, .foot-brand b span { color: var(--accent); }
.mark { width: 32px; height: 32px; border-radius: 9px; background: var(--accent); display: grid; place-items: center; }
.mark svg { width: 20px; height: 20px; fill: none; stroke: var(--accent-fg); stroke-width: 2; stroke-linejoin: round; }
.nav { display: flex; gap: 20px; font-size: 14.5px; }
.nav a { color: var(--muted); text-decoration: none; font-weight: 500; }
.nav a:hover { color: var(--fg); }
.btn { border: 0; border-radius: 999px; padding: 9px 16px; font-weight: 600; cursor: pointer; background: var(--accent-soft); color: var(--accent); white-space: nowrap; }
.btn.primary { background: var(--accent); color: var(--accent-fg); }
a.btn { text-decoration: none; display: inline-block; text-align: center; }
.btn.hot { background: var(--hot); color: #fff; }
.btn.ghost { background: transparent; color: var(--fg); border: 1px solid var(--line); }
.btn.light { background: #fff; color: #0b3f35; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.actions { display: flex; gap: 8px; align-items: center; margin-left: auto; }

.hero { background: var(--hero); color: #f1fbf8; position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(circle at 1px 1px, rgb(255 255 255 / .09) 1px, transparent 0); background-size: 22px 22px; mask-image: linear-gradient(90deg, transparent 30%, #000); pointer-events: none; }
.hero-in { position: relative; padding-block: 52px 44px; display: flex; flex-direction: column; gap: 14px; }
.eyebrow { margin: 0; font-size: 12.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #8fd8c6; }
.hero-title { margin: 0; font-family: var(--font-display); font-weight: 600; font-size: clamp(28px, 4.6vw, 46px); line-height: 1.15; letter-spacing: -0.02em; max-width: 20ch; text-wrap: balance; }
.hero-title em { font-style: normal; color: #ffb08f; }
.hero-sub { margin: 0; max-width: 58ch; color: #c5e3db; font-size: 16px; }
.search { margin-top: 10px; display: flex; align-items: center; gap: 6px; background: #fff; color: #16231f; border-radius: 14px; padding: 7px 7px 7px 14px; box-shadow: 0 12px 30px rgb(0 0 0 / .22); max-width: 860px; }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 10px 4px; outline: none; font-size: 16px; color: #16231f; }
.search select { border: 0; background: transparent; padding: 10px 4px; outline: none; font-size: 15px; color: #16231f; max-width: 200px; color-scheme: light; }
.s-ico svg { width: 20px; height: 20px; fill: none; stroke: #5b6b66; stroke-width: 2; stroke-linecap: round; display: block; }
.s-div { width: 1px; height: 28px; background: #dbe3e0; margin-inline: 6px; }
.s-btn { padding: 12px 22px; border-radius: 10px; background: #0e6e5c; color: #fff; }
.popular { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13.5px; color: #a9cfc5; }
.popular button { border: 1px solid rgb(255 255 255 / .22); background: rgb(255 255 255 / .06); color: #eaf7f3; border-radius: 999px; padding: 4px 12px; cursor: pointer; font-size: 13.5px; }
.popular button:hover { background: rgb(255 255 255 / .14); }

.sec { padding-block: 32px 4px; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.sec-head h2, .bar h2 { margin: 0; font-family: var(--font-display); font-size: 22px; font-weight: 600; letter-spacing: -0.01em; }
.link { border: 0; background: none; color: var(--accent); font-weight: 600; cursor: pointer; padding: 0; }
.cat-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.cat { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 16px 14px; cursor: pointer; text-align: left; font-size: 14px; font-weight: 600; line-height: 1.3; min-width: 0; transition: border-color .12s, transform .12s; }
.cat:hover { border-color: var(--c); transform: translateY(-1px); }
.cat i { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in oklab, var(--c) 15%, var(--surface)); }
.cat i svg, .thumb .ph svg { fill: none; stroke: var(--c); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.cat i svg { width: 24px; height: 24px; }
.cat small { display: block; font-weight: 400; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.cat[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); background: var(--accent-soft); }
@media (max-width: 980px) { .cat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } .nav { display: none; } }
@media (max-width: 640px) { .cat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; } .cat { padding: 12px 10px; font-size: 13px; } .cat small { display: none; } }

.steps { list-style: none; counter-reset: s; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 18px; display: flex; flex-direction: column; gap: 6px; }
.steps li::before { content: counter(s); width: 30px; height: 30px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; margin-bottom: 4px; }
.steps span { color: var(--muted); font-size: 14px; }
@media (max-width: 720px) { .steps { grid-template-columns: 1fr; } }
.cta { margin-block: 32px 40px; background: var(--hero); color: #f1fbf8; border-radius: 16px; padding: 26px 28px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.cta h2 { margin: 0 0 4px; font-family: var(--font-display); font-size: 22px; font-weight: 600; }
.cta p { margin: 0; color: #c5e3db; }
.foot { background: var(--surface); border-top: 1px solid var(--line); }
.foot-in { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 24px; padding-block: 32px 20px; }
.foot-brand b { font-family: var(--font-display); font-size: 20px; }
.foot-brand p { color: var(--muted); font-size: 13.5px; max-width: 32ch; }
.foot h3 { margin: 0 0 10px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.foot ul button { border: 0; background: none; padding: 0; cursor: pointer; color: var(--fg); text-align: left; }
.foot ul button:hover { color: var(--accent); }
.foot-note { color: var(--muted); font-size: 12.5px; padding-block: 14px 28px; border-top: 1px solid var(--line); }
@media (max-width: 760px) { .foot-in { grid-template-columns: 1fr 1fr; } .foot-brand { grid-column: 1 / -1; } }

.bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-block: 34px 14px; scroll-margin-top: 70px; }
.bar h2 { font-family: var(--font-display); font-size: 22px; font-weight: 600; margin: 0; text-wrap: balance; }
.bar .count { color: var(--muted); font-size: 13px; font-weight: 400; font-family: var(--font-body); }
.tabs { display: flex; gap: 4px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.tabs button { border: 0; background: transparent; padding: 5px 12px; border-radius: 999px; cursor: pointer; font-size: 13px; }
.tabs button[aria-pressed="true"] { background: var(--fg); color: var(--bg); }
.sort { border: 1px solid var(--line); background: var(--surface); border-radius: 8px; padding: 6px 8px; font-size: 13px; }

.notice { margin-block: 4px 10px; padding: 10px 14px; border-radius: var(--r); background: var(--accent-soft); color: var(--fg); font-size: 14px; }
.notice[data-kind="warn"] { background: color-mix(in oklab, var(--hot) 16%, var(--surface)); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 14px; padding-bottom: 40px; }
.card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; cursor: pointer; text-align: left; padding: 0; transition: transform .12s, box-shadow .12s; min-width: 0; }
.card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px color-mix(in oklab, var(--fg) 10%, transparent); }
.thumb { aspect-ratio: 4 / 3; max-width: 100%; position: relative; background: color-mix(in oklab, var(--c) 16%, var(--surface)); display: grid; place-items: center; overflow: hidden; }
.thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb .tag { z-index: 1; }
.thumb .ph { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 18px; background: color-mix(in oklab, var(--c) 14%, var(--surface)); }
.thumb .ph svg { width: 34px; height: 34px; }
.tag { position: absolute; top: 8px; left: 8px; font-size: 11px; font-weight: 600; letter-spacing: .03em; padding: 2px 8px; border-radius: 999px; background: var(--surface); color: var(--muted); border: 1px solid var(--line); }
.tag.off { left: auto; right: 8px; color: var(--hot); }
.body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.body h3 { margin: 0; font-size: 14.5px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { color: var(--price); font-weight: 700; font-variant-numeric: tabular-nums; }
.price small { font-weight: 500; color: var(--muted); }
.meta { margin-top: auto; padding-top: 4px; font-size: 12.5px; color: var(--muted); display: flex; justify-content: space-between; gap: 8px; }
.meta span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.meta span:last-child { flex: none; white-space: nowrap; }

.empty { grid-column: 1 / -1; text-align: center; padding: 48px 16px; color: var(--muted); border: 1.5px dashed var(--line); border-radius: var(--r); }
.empty b { display: block; color: var(--fg); font-size: 16px; margin-bottom: 4px; }

dialog { border: 0; border-radius: 14px; padding: 0; width: min(640px, calc(100vw - 24px)); max-height: calc(100dvh - 32px); background: var(--surface); color: var(--fg); }
dialog::backdrop { background: rgb(0 0 0 / .45); }
.dlg-head { position: sticky; top: 0; background: var(--surface); display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); z-index: 1; }
.dlg-head h2 { margin: 0; font-family: var(--font-display); font-size: 18px; font-weight: 600; }
.x { border: 0; background: var(--bg); width: 32px; height: 32px; border-radius: 50%; cursor: pointer; font-size: 18px; line-height: 1; }
.dlg-body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 14px; }

form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 520px) { form .row { grid-template-columns: 1fr; } }
label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 600; min-width: 0; }
label em { font-style: normal; font-weight: 400; color: var(--muted); }
.field { border: 1.5px solid var(--line); border-radius: 8px; padding: 9px 11px; background: var(--bg); font-weight: 400; font-size: 15px; width: 100%; }
.field:focus { border-color: var(--accent); outline: none; }
textarea.field { min-height: 110px; resize: vertical; }
.price-row { display: flex; gap: 8px; }
.price-row .field:first-child { flex: 1; min-width: 0; }
.price-row select { width: auto; }
.form-err { color: var(--hot); font-size: 14px; margin: 0; }
.form-foot { display: flex; justify-content: flex-end; gap: 8px; }

.d-hero { aspect-ratio: 21 / 9; max-width: 100%; border-radius: var(--r); }
.d-hero .ph { width: 88px; height: 88px; } .d-hero .ph svg { width: 46px; height: 46px; }
.d-title { margin: 0; font-family: var(--font-display); font-size: 21px; font-weight: 600; text-wrap: balance; }
.d-price { font-size: 20px; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; font-size: 14px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.d-desc { white-space: pre-wrap; margin: 0; line-height: 1.6; }
.contact { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 12px 14px; background: var(--bg); border-radius: var(--r); }
.contact .who { flex: 1; min-width: 150px; }
.contact .who b { display: block; }
.contact .phone { font-family: var(--font-display); font-size: 19px; font-weight: 600; letter-spacing: .02em; user-select: all; font-variant-numeric: tabular-nums; }
.owner-tools { display: flex; flex-wrap: wrap; gap: 8px; border-top: 1px solid var(--line); padding-top: 12px; }
.confirm { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; }

.toast { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--fg); color: var(--bg); padding: 9px 16px; border-radius: 999px; font-size: 14px; z-index: 20; }
footer { color: var(--muted); font-size: 12.5px; padding-block: 0 32px; }

/* Listings page */
.lhead { background: var(--surface); border-bottom: 1px solid var(--line); }
.lhead-in { padding-block: 14px 16px; display: flex; flex-direction: column; gap: 12px; }
.crumbs { font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--accent); }
.crumbs b { color: var(--fg); font-weight: 500; }
.lsearch { display: flex; gap: 8px; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; padding: 5px 5px 5px 12px; background: var(--bg); max-width: 860px; }
.lsearch:focus-within { border-color: var(--accent); }
.lsearch input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; padding: 8px 4px; font-size: 15px; }
.lsearch select { border: 0; border-left: 1px solid var(--line); background: transparent; outline: none; padding: 8px 8px; max-width: 190px; }
.lsearch .s-ico svg { stroke: var(--muted); }
.lsearch .btn { border-radius: 9px; }

.lbody { display: grid; grid-template-columns: 268px minmax(0, 1fr); gap: 28px; align-items: start; padding-block: 22px 48px; }
.filters { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.f-head { display: none; }
.f-group { padding: 16px 18px; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.f-group h3 { margin: 0 0 2px; font-size: 12.5px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); font-weight: 600; }
.f-cat { width: calc(100% + 16px); display: flex; align-items: center; gap: 10px; border: 0; background: transparent; padding: 6px 8px; margin-inline: -8px; border-radius: 8px; cursor: pointer; text-align: left; font-size: 14px; }
.f-cat:hover { background: var(--bg); }
.f-cat i { width: 26px; height: 26px; border-radius: 7px; flex: none; display: grid; place-items: center; background: color-mix(in oklab, var(--c) 15%, var(--surface)); }
.f-cat i svg { width: 16px; height: 16px; fill: none; stroke: var(--c); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.f-cat span { flex: 1; min-width: 0; }
.f-cat small { color: var(--muted); font-variant-numeric: tabular-nums; }
.f-cat[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.f-ranges { display: flex; flex-wrap: wrap; gap: 6px; }
.f-ranges button { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 5px 11px; font-size: 13px; cursor: pointer; }
.f-ranges button[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.f-minmax { display: flex; align-items: center; gap: 6px; }
.f-minmax input { flex: 1; min-width: 0; border: 1.5px solid var(--line); border-radius: 8px; padding: 7px 9px; background: var(--bg); font-size: 14px; }
.f-minmax input:focus { border-color: var(--accent); outline: none; }
.chk { flex-direction: row; align-items: center; gap: 10px; font-weight: 400; font-size: 14px; cursor: pointer; }
.chk input { width: 18px; height: 18px; accent-color: var(--accent); margin: 0; }
.f-foot { padding: 14px 18px; display: flex; gap: 8px; }
.f-foot .apply { display: none; }

.r-top { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; }
.r-top h1 { margin: 0; font-family: var(--font-display); font-size: 24px; font-weight: 600; letter-spacing: -0.01em; text-wrap: balance; }
.r-top p { margin: 0; color: var(--muted); font-size: 14px; }
.r-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 14px; padding: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.r-bar .grow { flex: 1; }
.filter-btn { display: none; align-items: center; gap: 6px; }
.filter-btn svg, .view-tg svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.filter-btn b { background: var(--accent); color: var(--accent-fg); border-radius: 999px; font-size: 11px; min-width: 18px; height: 18px; display: inline-grid; place-items: center; padding-inline: 5px; }
.view-tg { display: flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.view-tg button { border: 0; background: var(--surface); color: var(--muted); padding: 6px 9px; cursor: pointer; display: grid; place-items: center; }
.view-tg button[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.chips:empty { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--accent); color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 4px 6px 4px 12px; font-size: 13px; font-weight: 500; cursor: pointer; }
.chip span { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in oklab, var(--accent) 18%, transparent); font-size: 13px; line-height: 1; }
.chip.clear { border-color: transparent; background: transparent; color: var(--muted); padding-right: 10px; }
#lNotice { margin-top: 12px; }

.rows { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.rows.grid { display: grid; gap: 14px; padding-bottom: 0; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.ritem { display: grid; grid-template-columns: 220px minmax(0, 1fr) 190px; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px; cursor: pointer; transition: border-color .12s, box-shadow .12s; }
.ritem:hover { border-color: color-mix(in oklab, var(--accent) 45%, var(--line)); box-shadow: 0 6px 18px color-mix(in oklab, var(--fg) 8%, transparent); }
.ritem .thumb { border-radius: 10px; aspect-ratio: 4 / 3; }
.r-main { display: flex; flex-direction: column; gap: 5px; min-width: 0; padding-block: 2px; }
.r-cat { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--c); }
.r-cat .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.r-main h3 { margin: 0; font-size: 16.5px; font-weight: 600; line-height: 1.35; }
.r-desc { margin: 0; color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.r-meta { margin-top: auto; display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--muted); }
.r-meta span { display: inline-flex; align-items: center; gap: 4px; }
.r-meta svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.r-side { display: flex; flex-direction: column; align-items: flex-end; justify-content: space-between; gap: 10px; border-left: 1px solid var(--line); padding-left: 16px; text-align: right; }
.r-side .price { font-size: 18px; }
.r-who { font-size: 13px; color: var(--muted); }
.r-who b { display: block; color: var(--fg); font-weight: 600; font-size: 14px; }
.r-side .btn { width: 100%; }
.more { display: flex; justify-content: center; margin-top: 20px; }
.more:empty { display: none; }
.sec-head a.link { text-decoration: none; }

@media (max-width: 1080px) { .ritem { grid-template-columns: 180px minmax(0, 1fr) 170px; } }
@media (max-width: 900px) {
  .lbody { grid-template-columns: minmax(0, 1fr); padding-block: 16px 40px; }
  .filters { position: fixed; inset: 0; z-index: 30; border-radius: 0; border: 0; max-height: none; padding-bottom: env(safe-area-inset-bottom, 0px); padding-top: env(safe-area-inset-top, 0px); transform: translateY(100%); visibility: hidden; transition: transform .22s ease, visibility 0s .22s; display: flex; flex-direction: column; }
  .filters.open { transform: none; visibility: visible; transition: transform .22s ease; }
  .f-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--surface); z-index: 1; }
  .f-head h2 { margin: 0; font-family: var(--font-display); font-size: 18px; font-weight: 600; }
  .f-scroll { flex: 1; overflow: auto; }
  .f-foot { position: sticky; bottom: 0; background: var(--surface); border-top: 1px solid var(--line); }
  .f-foot .apply { display: inline-block; flex: 1; }
  .filter-btn { display: inline-flex; }
  .r-bar .tabs { order: 5; }
}
@media (max-width: 640px) {
  .lsearch { flex-wrap: wrap; padding: 5px; }
  .lsearch input { flex: 1 1 calc(100% - 40px); }
  .lsearch select { flex: 1; border-left: 0; max-width: none; border-top: 1px solid var(--line); }
  .r-top h1 { font-size: 20px; }
  .ritem { grid-template-columns: 112px minmax(0, 1fr); gap: 12px; padding: 10px; border-radius: 12px; }
  .ritem .thumb { aspect-ratio: 1; }
  .ritem .thumb .ph { width: 48px; height: 48px; border-radius: 14px; } .ritem .thumb .ph svg { width: 26px; height: 26px; }
  .ritem .tag { font-size: 10px; top: 6px; left: 6px; padding: 1px 6px; }
  .r-main h3 { font-size: 14.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .r-desc, .r-who, .r-side .btn { display: none; }
  .r-side { grid-column: 2; border: 0; padding: 0; flex-direction: row; align-items: center; margin-top: -6px; }
  .r-side .price { font-size: 15px; }
  .r-meta { font-size: 12px; }
  .r-meta .r-time { display: none; }
  .rows.grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* Detail page */
.dv-body { padding-block: 18px 56px; display: flex; flex-direction: column; gap: 18px; }
.dv-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.dv-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; }
.panel h2 { margin: 0 0 12px; font-family: var(--font-display); font-size: 17px; font-weight: 600; }
.dv-gallery { padding: 10px; }
.dv-gallery .thumb { aspect-ratio: 16 / 9; border-radius: 10px; }
.dv-gallery .ph { width: 96px; height: 96px; border-radius: 26px; } .dv-gallery .ph svg { width: 50px; height: 50px; }
.dv-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--c); background: color-mix(in oklab, var(--c) 12%, var(--surface)); border-radius: 999px; padding: 3px 10px 3px 4px; }
.dv-pill i { width: 20px; height: 20px; display: grid; place-items: center; }
.dv-pill svg { width: 14px; height: 14px; fill: none; stroke: var(--c); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.dv-title { margin: 10px 0 6px; font-family: var(--font-display); font-size: clamp(22px, 3vw, 28px); font-weight: 600; line-height: 1.25; letter-spacing: -0.01em; text-wrap: balance; }
.dv-price { font-size: 26px; }
.dv-price .price small { font-size: 16px; }
.dv-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; font-size: 14px; color: var(--muted); }
.dv-meta span { display: inline-flex; align-items: center; gap: 5px; }
.dv-meta svg, .tips svg, .side-note svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.spec { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 24px; margin: 0; }
.spec div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--line); font-size: 14px; min-width: 0; }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; font-weight: 500; text-align: right; min-width: 0; overflow-wrap: anywhere; }
.dv-desc { margin: 0; white-space: pre-wrap; line-height: 1.7; font-size: 15px; }
.tips { background: color-mix(in oklab, var(--hot) 7%, var(--surface)); border-color: color-mix(in oklab, var(--hot) 25%, var(--line)); }
.tips ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.tips li { display: flex; gap: 8px; } .tips li svg { color: var(--hot); margin-top: 3px; }
.side { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); display: flex; flex-direction: column; gap: 14px; }
.who-card { display: flex; flex-direction: column; gap: 14px; }
.who-row { display: flex; align-items: center; gap: 12px; }
.avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; font-size: 20px; flex: none; }
.who-row b { display: block; font-size: 16px; }
.who-row small { color: var(--muted); font-size: 13px; }
.phone-box { display: flex; flex-direction: column; gap: 8px; }
.phone-num { font-family: var(--font-display); font-size: 22px; font-weight: 600; letter-spacing: .03em; text-align: center; padding: 10px; border-radius: 10px; background: var(--bg); font-variant-numeric: tabular-nums; user-select: all; }
.btn.block { width: 100%; padding: 12px 16px; font-size: 15px; }
.side-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.btn[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); border-color: var(--accent); }
.side-note { display: flex; gap: 8px; color: var(--muted); font-size: 13px; margin: 0; }
.owner-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.related .grid { padding-bottom: 0; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.callbar { display: none; }
.dv-missing { text-align: center; padding: 60px 16px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.dv-missing h1 { margin: 0; font-family: var(--font-display); font-size: 22px; }
@media (max-width: 900px) {
  .dv-grid { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; }
  .side .phone-box { display: none; }
  .related .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  #detailView { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
  .callbar { display: flex; align-items: center; gap: 12px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -6px 18px color-mix(in oklab, var(--fg) 8%, transparent); padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
  .callbar .cb-price { flex: 1; min-width: 0; font-size: 13px; color: var(--muted); }
  .callbar .cb-price .price { display: block; font-size: 17px; }
  .callbar .btn { padding: 12px 18px; font-size: 15px; }
}
@media (max-width: 640px) {
  .panel { padding: 16px; }
  .dv-gallery { padding: 0; overflow: hidden; } .dv-gallery .thumb { border-radius: 0; aspect-ratio: 4 / 3; }
  .spec { grid-template-columns: minmax(0, 1fr); }
  .dv-price { font-size: 22px; }
  .dv-body { gap: 12px; padding-top: 12px; }
  .crumbs.dv-crumbs { display: none; }
}
/* Guides (news) */
.nhead { background: var(--surface); border-bottom: 1px solid var(--line); }
.nhead-in { padding-block: 28px 0; display: flex; flex-direction: column; gap: 6px; }
.nhead h1 { margin: 0; font-family: var(--font-display); font-size: clamp(26px, 3.6vw, 34px); font-weight: 600; letter-spacing: -0.02em; }
.nhead p { margin: 0; color: var(--muted); max-width: 62ch; }
.ntabs { display: flex; gap: 4px; overflow-x: auto; margin-top: 14px; scrollbar-width: none; }
.ntabs button { flex: none; border: 0; background: none; padding: 10px 14px; font-weight: 500; color: var(--muted); border-bottom: 2.5px solid transparent; cursor: pointer; }
.ntabs button[aria-pressed="true"] { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }
.nbody { padding-block: 26px 56px; display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
.nmain { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.cover { position: relative; background: color-mix(in oklab, var(--c) 14%, var(--surface)); display: grid; place-items: center; overflow: hidden; aspect-ratio: 16 / 9; max-width: 100%; }
.cover::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(circle at 1px 1px, color-mix(in oklab, var(--c) 30%, transparent) 1px, transparent 0); background-size: 18px 18px; opacity: .55; }
.cover .ph { position: relative; width: 30%; max-width: 120px; aspect-ratio: 1; border-radius: 28%; background: var(--surface); display: grid; place-items: center; box-shadow: 0 10px 30px color-mix(in oklab, var(--c) 25%, transparent); }
.cover .ph svg { width: 52%; height: 52%; fill: none; stroke: var(--c); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.a-cat { font-size: 12.5px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--c); }
.a-meta { font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 12px; }
.feature { display: grid; grid-template-columns: 1.25fr 1fr; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; cursor: pointer; text-align: left; padding: 0; }
.feature .cover { aspect-ratio: auto; min-height: 280px; }
.feature .f-txt { padding: 26px 26px 22px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.feature h2 { margin: 0; font-family: var(--font-display); font-size: 24px; font-weight: 600; line-height: 1.3; text-wrap: balance; }
.feature p { margin: 0; color: var(--muted); }
.feature .read { margin-top: auto; color: var(--accent); font-weight: 600; font-size: 14px; }
.agrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.acard { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; cursor: pointer; text-align: left; padding: 0; transition: transform .12s, box-shadow .12s; min-width: 0; }
.acard:hover, .feature:hover { box-shadow: 0 8px 22px color-mix(in oklab, var(--fg) 9%, transparent); }
.acard:hover { transform: translateY(-2px); }
.acard .a-txt { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.acard h3 { margin: 0; font-size: 16px; font-weight: 600; line-height: 1.4; }
.acard p { margin: 0; color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.acard .a-meta { margin-top: auto; padding-top: 4px; }
.nside { display: flex; flex-direction: column; gap: 16px; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 76px); }
.popular-list { list-style: none; counter-reset: p; margin: 0; padding: 0; display: flex; flex-direction: column; }
.popular-list li { counter-increment: p; border-top: 1px solid var(--line); }
.popular-list li:first-child { border-top: 0; }
.popular-list button { display: grid; grid-template-columns: 28px 1fr; gap: 10px; border: 0; background: none; padding: 11px 0; text-align: left; cursor: pointer; font-size: 14px; font-weight: 500; line-height: 1.4; width: 100%; }
.popular-list button::before { content: counter(p, decimal-leading-zero); font-family: var(--font-display); font-weight: 700; color: var(--accent); font-size: 15px; }
.popular-list button:hover { color: var(--accent); }
.side-cta { background: var(--hero); color: #f1fbf8; border: 0; }
.side-cta h2 { color: #fff; }
.side-cta p { margin: 0 0 12px; color: #c5e3db; font-size: 14px; }

.art { padding-block: 18px 56px; }
.art-grid { display: grid; grid-template-columns: 220px minmax(0, 720px) 1fr; gap: 36px; align-items: start; }
.toc { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 80px); font-size: 14px; }
.toc h2 { margin: 0 0 8px; font-size: 12.5px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.toc ol { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 2px; border-left: 2px solid var(--line); }
.toc button { border: 0; background: none; text-align: left; cursor: pointer; padding: 6px 12px; margin-left: -2px; border-left: 2px solid transparent; color: var(--muted); line-height: 1.4; }
.toc button:hover { color: var(--fg); }
.toc button.on { color: var(--accent); border-left-color: var(--accent); font-weight: 600; }
.art-head { display: flex; flex-direction: column; gap: 10px; }
.art-head h1 { margin: 0; font-family: var(--font-display); font-size: clamp(26px, 4vw, 38px); font-weight: 600; line-height: 1.2; letter-spacing: -0.02em; text-wrap: balance; }
.art-lead { margin: 0; font-size: 18px; color: var(--muted); line-height: 1.6; }
.byline { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); }
.byline .avatar { width: 36px; height: 36px; font-size: 15px; }
.byline b { color: var(--fg); font-weight: 600; display: block; }
.art .cover { border-radius: 16px; margin-block: 22px 6px; aspect-ratio: 21 / 9; }
.prose { font-size: 17px; line-height: 1.75; }
.prose h2 { font-family: var(--font-display); font-size: 23px; font-weight: 600; margin: 34px 0 10px; line-height: 1.3; scroll-margin-top: 84px; letter-spacing: -0.01em; }
.prose p { margin: 0 0 14px; }
.prose ul, .prose ol { margin: 0 0 16px; padding-left: 1.3em; display: flex; flex-direction: column; gap: 6px; }
.prose li::marker { color: var(--accent); font-weight: 700; }
.prose strong { font-weight: 600; }
.callout { margin: 20px 0; padding: 16px 18px; border-radius: 12px; background: var(--accent-soft); border-left: 4px solid var(--accent); font-size: 16px; }
.callout b { display: block; margin-bottom: 4px; color: var(--accent); }
.prose .tbl { overflow-x: auto; margin: 0 0 18px; border: 1px solid var(--line); border-radius: 10px; }
.prose table { border-collapse: collapse; width: 100%; font-size: 15px; min-width: 460px; }
.prose th, .prose td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.prose th { background: var(--bg); font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }
.find-box { margin-top: 30px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; padding: 20px 22px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.find-box .ico { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: color-mix(in oklab, var(--c) 15%, var(--surface)); flex: none; }
.find-box .ico svg { width: 28px; height: 28px; fill: none; stroke: var(--c); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.find-box div { flex: 1; min-width: 200px; }
.find-box b { display: block; font-size: 16px; }
.find-box span { color: var(--muted); font-size: 14px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.tags span { font-size: 13px; padding: 4px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--muted); }
.art-related { margin-top: 44px; }
.toc-m { display: none; }
@media (max-width: 1080px) { .art-grid { grid-template-columns: 200px minmax(0, 1fr); } .art-grid > .spacer { display: none; } }
@media (max-width: 900px) {
  .nbody { grid-template-columns: minmax(0, 1fr); }
  .nside { position: static; }
  .agrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .feature { grid-template-columns: minmax(0, 1fr); }
  .feature .cover { min-height: 0; aspect-ratio: 16 / 9; }
  .art-grid { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .toc { display: none; }
  .toc-m { display: block; margin-top: 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
  .toc-m summary { padding: 12px 16px; font-weight: 600; cursor: pointer; }
  .toc-m ol { margin: 0; padding: 0 16px 12px 34px; display: flex; flex-direction: column; gap: 4px; font-size: 15px; }
  .toc-m button { border: 0; background: none; padding: 4px 0; text-align: left; color: var(--accent); cursor: pointer; }
}
@media (max-width: 640px) {
  .agrid { grid-template-columns: minmax(0, 1fr); }
  .acard { display: grid; grid-template-columns: 112px minmax(0, 1fr); }
  .acard .cover { aspect-ratio: auto; height: 100%; min-height: 112px; }
  .acard .cover .ph { width: 52px; border-radius: 14px; }
  .acard .a-txt { padding: 10px 12px; gap: 5px; }
  .acard h3 { font-size: 15px; }
  .acard p { display: none; }
  .feature .f-txt { padding: 18px; }
  .feature h2 { font-size: 20px; }
  .prose { font-size: 16px; }
  .art-lead { font-size: 16px; }
  .art .cover { aspect-ratio: 16 / 9; border-radius: 12px; }
}
@media (prefers-reduced-motion: reduce) { .filters, .filters.open { transition: none; } }
@media (prefers-reduced-motion: reduce) { .card { transition: none; } .card:hover { transform: none; } }
@media (max-width: 640px) {
  #mineBtn { display: none; }
  .hero-in { padding-block: 32px 28px; }
  .search { flex-wrap: wrap; padding: 6px; gap: 4px; }
  .search input { flex: 1 1 calc(100% - 40px); }
  .s-div { display: none; }
  .search select { flex: 1; max-width: none; }
  .s-btn { flex: 1 1 100%; }
  .cta { padding: 22px 20px; }
}

/* ===== Bổ sung cho bản PHP (liên kết thay nút, menu, form, thông báo) ===== */
a.card, a.ritem, a.acard, a.feature, a.cat, a.f-cat, .mine a { color: inherit; text-decoration: none; }

a.feature { display: grid; }
.nav a[aria-current="page"] { color: var(--accent); }
.popular a { border: 1px solid rgb(255 255 255 / .22); background: rgb(255 255 255 / .06); color: #eaf7f3; border-radius: 999px; padding: 4px 12px; font-size: 13.5px; text-decoration: none; }
.popular a:hover { background: rgb(255 255 255 / .14); }
.foot ul a { color: var(--fg); text-decoration: none; }
.foot ul a:hover { color: var(--accent); }
.f-cat[aria-current="true"] { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.f-ranges a { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 5px 11px; font-size: 13px; color: var(--fg); text-decoration: none; }
.f-ranges a[aria-current="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.view-tg a { background: var(--surface); color: var(--muted); padding: 6px 9px; display: grid; place-items: center; }
.view-tg a[aria-current="true"] { background: var(--accent-soft); color: var(--accent); }
.ntabs a { flex: none; padding: 10px 14px; font-weight: 500; color: var(--muted); border-bottom: 2.5px solid transparent; text-decoration: none; }
.ntabs a[aria-current="true"] { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }
.chip { text-decoration: none; }
.popular-list a { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 11px 0; font-size: 14px; font-weight: 500; line-height: 1.4; color: var(--fg); text-decoration: none; }
.popular-list a::before { content: counter(p, decimal-leading-zero); font-family: var(--font-display); font-weight: 700; color: var(--accent); font-size: 15px; }
.popular-list a:hover { color: var(--accent); }
.toc a { display: block; padding: 6px 12px; margin-left: -2px; border-left: 2px solid transparent; color: var(--muted); line-height: 1.4; text-decoration: none; }
.toc a:hover { color: var(--fg); }
.toc a.on { color: var(--accent); border-left-color: var(--accent); font-weight: 600; }
.toc-m a { color: var(--accent); text-decoration: none; }
.f-foot .apply-desk { display: inline-block; }
.f-foot .btn.ghost { text-align: center; }
.side-actions form { margin: 0; }
.owner-tools form { margin: 0; }
.ritem span.btn { text-align: center; }

/* Menu tài khoản / menu điện thoại */
.menu { position: relative; }
.menu summary { list-style: none; display: inline-flex; align-items: center; gap: 8px; }
.menu summary::-webkit-details-marker { display: none; }
.menu-pop { position: absolute; right: 0; top: calc(100% + 8px); min-width: 200px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 30px color-mix(in oklab, var(--fg) 14%, transparent); padding: 6px; display: flex; flex-direction: column; z-index: 20; }
.menu-pop a, .menu-pop button { display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px; color: var(--fg); text-decoration: none; border: 0; background: none; cursor: pointer; font-size: 14.5px; }
.menu-pop a:hover, .menu-pop button:hover { background: var(--bg); }
.menu-pop form { margin: 0; }
.avatar.sm { width: 26px; height: 26px; font-size: 13px; }
.icon-btn { padding: 8px 10px; }
.icon-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; display: block; }
.mobile-nav { display: none; }
@media (max-width: 980px) { .mobile-nav { display: block; } }
@media (max-width: 640px) { .hide-sm { display: none !important; } .actions { gap: 6px; } }

/* Thông báo */
.flashes { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 74px); left: 50%; transform: translateX(-50%); z-index: 25; display: flex; flex-direction: column; gap: 8px; width: min(560px, calc(100% - 32px)); }
.flash { padding: 12px 16px; border-radius: 12px; background: var(--fg); color: var(--bg); font-size: 14.5px; box-shadow: 0 10px 26px color-mix(in oklab, var(--fg) 25%, transparent); animation: flash-out 0.4s ease 5s forwards; }
.flash-info { background: var(--accent); color: var(--accent-fg); }
@keyframes flash-out { to { opacity: 0; visibility: hidden; transform: translateY(-8px); } }
@media (prefers-reduced-motion: reduce) { .flash { animation-duration: 0s; } }

/* Trang form, đăng nhập */
.form-page { padding-block: 20px 56px; display: flex; flex-direction: column; gap: 16px; }
.form-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.form-card { display: flex; flex-direction: column; gap: 14px; }
.form-card h1, .auth-card h1, .form-page .r-top h1 { margin: 0; font-family: var(--font-display); font-size: 24px; font-weight: 600; }
.form-tips ul { margin: 0 0 12px; padding-left: 1.2em; display: flex; flex-direction: column; gap: 8px; font-size: 14px; color: var(--muted); }
.f-err { color: var(--hot); font-weight: 500; font-size: 13px; }
.form-alert { margin: 0; padding: 10px 14px; border-radius: 10px; background: color-mix(in oklab, var(--hot) 12%, var(--surface)); color: var(--fg); font-size: 14px; }
.cur-img { display: flex; align-items: center; gap: 14px; }
.cur-img img { width: 120px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; }
.auth-page { padding-block: 40px 64px; display: grid; place-items: center; }
.auth-card { width: min(440px, 100%); display: flex; flex-direction: column; gap: 14px; }
.muted { color: var(--muted); margin: 0; font-size: 14px; }
.center { text-align: center; }
@media (max-width: 900px) { .form-grid { grid-template-columns: minmax(0, 1fr); } }

/* Tin của tôi */
.mine { display: flex; flex-direction: column; gap: 12px; }
.mine-item { display: grid; grid-template-columns: 160px minmax(0, 1fr) auto; gap: 16px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px; }
.mine-thumb .thumb { border-radius: 10px; }
.mine-main { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.mine-main h3 { margin: 0; font-size: 16px; font-weight: 600; }
.status { align-self: flex-start; font-size: 12.5px; font-weight: 600; padding: 2px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); }
.status.paused { background: color-mix(in oklab, var(--hot) 14%, var(--surface)); color: var(--hot); }
.mine-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.mine-actions form { margin: 0; }
@media (max-width: 720px) { .mine-item { grid-template-columns: 96px minmax(0, 1fr); } .mine-actions { grid-column: 1 / -1; justify-content: flex-start; } }

/* Phân trang */
.pager { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px; margin-top: 22px; }
.pg { min-width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); text-decoration: none; font-weight: 500; }
.pg.on { background: var(--accent); color: var(--accent-fg); border-color: var(--accent); }
@media (max-width: 900px) { .f-foot .apply-desk { display: none; } }
.menu:not([open]) .menu-pop { display: none; }
@media (max-width: 420px) { .brand b { font-size: 19px; } .mark { width: 28px; height: 28px; } .top .wrap { gap: 8px; } .btn.hot { padding: 9px 12px; } }

/* Nội dung bài viết soạn từ trang quản trị */
.prose h3 { font-family: var(--font-display); font-size: 19px; font-weight: 600; margin: 26px 0 8px; line-height: 1.35; }
.prose a { color: var(--accent); text-underline-offset: 3px; }
.prose figure { margin: 22px 0; }
.prose img { display: block; max-width: 100%; height: auto; border-radius: 12px; background: var(--line); }
.prose figcaption { margin-top: 8px; font-size: 14px; color: var(--muted); text-align: center; }
.prose blockquote { margin: 20px 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--accent); color: var(--muted); font-style: italic; }
.prose blockquote p:last-child { margin-bottom: 0; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 28px 0; }
.callout strong:first-child { display: block; margin-bottom: 4px; color: var(--accent); }
.callout p:last-child { margin-bottom: 0; }
.preview-bar { margin-top: 16px; padding: 10px 14px; border-radius: 10px; background: #fff4d6; color: #6b4a00; font-size: 14px; }
.preview-bar a { color: inherit; font-weight: 600; }

/* ===== Giá trị từ “Cài đặt website” ===== */
.brand-img { display: block; height: 40px; width: auto; max-width: 200px; object-fit: contain; }
.hero.has-img { background: linear-gradient(100deg, rgb(8 40 33 / .9) 0%, rgb(8 40 33 / .62) 50%, rgb(8 40 33 / .2) 100%), var(--hero-img) center / cover no-repeat, var(--hero); }
.hero.has-img::before { display: none; }
.thumb img.def-img, .def-img { object-fit: cover; }
.foot-brand p { margin: 0 0 12px; }
.foot-contact { gap: 8px !important; margin-bottom: 14px !important; }
.foot-contact li { display: flex; align-items: flex-start; gap: 9px; color: var(--fg); }
.foot-contact svg { width: 17px; height: 17px; flex: none; margin-top: 2px; color: var(--accent); fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.foot-contact a, .foot-contact span { color: var(--fg); text-decoration: none; overflow-wrap: anywhere; }
.foot-contact a:hover { color: var(--accent); }
.foot-social { display: flex; gap: 8px; }
.foot-social a { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--bg); color: var(--fg); border: 1px solid var(--line); }
.foot-social a:hover { color: var(--accent); border-color: var(--accent); }
.foot-social svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.float-contact { position: fixed; right: 16px; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); z-index: 40; display: flex; flex-direction: column; gap: 10px; }
.float-contact.has-oa { bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
.float-contact a { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; color: #fff; text-decoration: none; box-shadow: 0 6px 18px rgb(0 0 0 / .22); }
.fc-call { background: var(--hot); animation: fc-ring 2.4s ease-in-out infinite; }
.fc-call svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fc-zalo { background: #0068ff; font: 700 13px/1 var(--font-body, system-ui), sans-serif; letter-spacing: .01em; }
@keyframes fc-ring { 0%, 70%, 100% { transform: none; } 75% { transform: rotate(-12deg); } 80% { transform: rotate(12deg); } 85% { transform: rotate(-8deg); } 90% { transform: rotate(6deg); } }
@media (prefers-reduced-motion: reduce) { .fc-call { animation: none; } }
.policy-h { font-family: var(--font-display); font-size: clamp(26px, 3.6vw, 34px); line-height: 1.2; margin: 0 0 8px; }

.mark svg.pin { width: 24px; height: 24px; stroke: none; color: var(--accent); }
.brand picture { display: block; }
.thumb .def-img { position: absolute; inset: 0; }
.thumb .def-cat { position: absolute; right: 8px; bottom: 8px; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--surface); box-shadow: 0 2px 6px rgb(0 0 0 / .12); }
.thumb .def-cat svg { width: 17px; height: 17px; fill: none; stroke: var(--c); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
/* Trang chi tiết: hiện trọn ảnh thật (không cắt mất logo đóng dấu) */
.d-hero:has(.real-img), .dv-gallery .thumb:has(.real-img) { aspect-ratio: auto; background: color-mix(in oklab, var(--c) 8%, var(--surface)); }
.d-hero .real-img, .dv-gallery .real-img { position: static; width: 100%; height: auto; max-height: 640px; object-fit: contain; }

/* ===== Tin nổi bật / VIP ===== */
:root { --vip: #b7791f; --vip-soft: #fdf3dc; --feat: #d9542f; --feat-soft: #fde9e2; }
.tier-badge { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; letter-spacing: .02em; padding: 2px 9px; border-radius: 999px; white-space: nowrap; }
.tier-badge.tier-vip { background: linear-gradient(135deg, #f6c453, #d99a1e); color: #3d2600; }
.tier-badge.tier-featured { background: var(--feat); color: #fff; }
.tier-badge.tier-normal { background: var(--bg); color: var(--muted); border: 1px solid var(--line); }
.thumb .tier-pin { position: absolute; top: 8px; right: 8px; z-index: 1; }
.card.tier-vip, .ritem.tier-vip { border-color: #e2b04a; box-shadow: 0 0 0 1px #e2b04a, 0 8px 22px rgb(183 121 31 / .14); }
.card.tier-featured, .ritem.tier-featured { border-color: color-mix(in oklab, var(--feat) 55%, var(--line)); box-shadow: 0 0 0 1px color-mix(in oklab, var(--feat) 40%, transparent); }
.ritem.tier-vip { background: linear-gradient(90deg, var(--vip-soft), var(--surface) 40%); }
.dv-title { margin-top: 8px; }
.dv-pill + .tier-badge { margin-left: 6px; }

/* Chọn gói */
.plans { border: 0; padding: 0; margin: 4px 0 0; min-width: 0; }
.plans legend { font-size: 13px; font-weight: 600; margin-bottom: 8px; padding: 0; }
.plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.plan { border: 1.5px solid var(--line); border-radius: 14px; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--surface); font-weight: 400; font-size: 14px; cursor: default; }
label.plan { cursor: pointer; }
.plan:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 2px color-mix(in oklab, var(--accent) 25%, transparent); }
.plan-vip { background: linear-gradient(180deg, var(--vip-soft), var(--surface) 60%); }
.plan-vip:has(input:checked) { border-color: var(--vip); box-shadow: 0 0 0 2px color-mix(in oklab, var(--vip) 30%, transparent); }
.plan-featured:has(input:checked) { border-color: var(--feat); box-shadow: 0 0 0 2px color-mix(in oklab, var(--feat) 25%, transparent); }
.plan-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.plan-head b { font-size: 15px; }
.plan-price { margin-left: auto; font-weight: 700; color: var(--accent); }
.plan ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 13px; display: flex; flex-direction: column; gap: 3px; }
.plan-days { display: flex; flex-direction: column; gap: 6px; margin-top: auto; }
.plan-days label { flex-direction: row; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 500; font-size: 13.5px; background: var(--surface); }
.plan-days label b { margin-left: auto; color: var(--price); }
.plan-days label:has(input:checked) { border-color: currentColor; background: var(--accent-soft); }
.plan input { accent-color: var(--accent); margin: 0; }
@media (max-width: 760px) { .plan-grid { grid-template-columns: minmax(0, 1fr); } }

/* Nâng cấp & thanh toán */
.up-card, .pay-card { max-width: 920px; }
.up-listing { display: flex; gap: 14px; align-items: center; padding: 12px; border-radius: 12px; background: var(--bg); }
.up-listing > div:last-child { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.up-thumb { width: 120px; flex: none; } .up-thumb .thumb { border-radius: 10px; }
.pay-card { display: flex; flex-direction: column; gap: 16px; }
.pay-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.pay-head h1 { margin: 0; font-family: var(--font-display); font-size: 24px; }
.pay-head p { margin: 4px 0 0; }
.pay-status { font-size: 12.5px; font-weight: 700; padding: 4px 12px; border-radius: 999px; white-space: nowrap; }
.pay-status.st-pending { background: var(--vip-soft); color: #8a5a00; }
.pay-status.st-paid { background: var(--accent-soft); color: var(--accent); }
.pay-status.st-cancelled { background: var(--bg); color: var(--muted); }
.pay-grid { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; align-items: start; }
.pay-qr img { width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); background: #fff; display: block; }
.pay-qr p { margin: 8px 0 0; text-align: center; }
.pay-noqr { padding: 18px; border-radius: 12px; background: var(--bg); line-height: 1.6; }
.pay-info { margin: 0; display: flex; flex-direction: column; }
.pay-info > div { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); align-items: center; }
.pay-info dt { color: var(--muted); font-size: 14px; }
.pay-info dd { margin: 0; font-weight: 600; text-align: right; display: flex; align-items: center; gap: 8px; }
.pay-info dd.price { font-size: 22px; color: var(--price); }
.pay-info code { font-size: 17px; letter-spacing: .04em; background: var(--vip-soft); padding: 3px 8px; border-radius: 6px; }
.btn.sm { padding: 5px 12px; font-size: 13px; }
.pay-wait { display: flex; align-items: center; gap: 10px; margin: 0; padding: 12px 14px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); font-weight: 600; font-size: 14px; }
.spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin 1s linear infinite; flex: none; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spin { animation-duration: 4s; } }
.pay-ok { padding: 16px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.pay-ok .btn { margin-left: auto; }
.pay-ok.cancelled { background: var(--bg); color: var(--muted); }
.link-btn { background: none; border: 0; padding: 0; color: var(--muted); text-decoration: underline; cursor: pointer; font-size: 13.5px; }
@media (max-width: 720px) { .pay-grid { grid-template-columns: minmax(0, 1fr); } .pay-qr { max-width: 300px; margin: 0 auto; } }

/* Tài khoản */
.acc { gap: 16px; }
.acc-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.avatar.lg { width: 64px; height: 64px; font-size: 28px; }
.acc-who { flex: 1; min-width: 0; }
.acc-who h1 { margin: 0; font-family: var(--font-display); font-size: 24px; }
.acc-who p { margin: 2px 0 0; }
.acc-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.acc-stats .panel { padding: 16px; display: flex; flex-direction: column; gap: 2px; }
.acc-stats b { font-family: var(--font-display); font-size: 26px; }
.acc-stats span { color: var(--muted); font-size: 13.5px; }
.acc-alert { padding: 12px 16px; border-radius: 12px; background: var(--vip-soft); color: #6b4500; display: flex; gap: 10px; flex-wrap: wrap; align-items: center; font-size: 14px; }
.acc-alert a { font-weight: 700; color: inherit; }
.acc-sec-h { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.acc-list { display: flex; flex-direction: column; gap: 10px; }
.acc-item { display: grid; grid-template-columns: 112px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: 12px; }
.acc-item.tier-vip { border-color: #e2b04a; background: linear-gradient(90deg, var(--vip-soft), var(--surface) 45%); }
.acc-item.tier-featured { border-color: color-mix(in oklab, var(--feat) 50%, var(--line)); }
.acc-thumb .thumb { border-radius: 9px; }
.acc-main { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.acc-main a { color: var(--fg); text-decoration: none; }
.acc-main h3 { margin: 0; font-size: 15.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acc-tags { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.acc-tags .status { align-self: auto; }
.acc-act { display: flex; gap: 8px; }
.table-wrap { overflow-x: auto; }
.otable { width: 100%; border-collapse: collapse; font-size: 14px; }
.otable th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.otable td { padding: 10px; border-bottom: 1px solid var(--line); }
.otable .num { text-align: right; white-space: nowrap; }
.otable a { color: var(--accent); font-weight: 600; }
.acc-forms { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.acc-forms h2 { margin: 0; }
@media (max-width: 760px) {
  .acc-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .acc-forms { grid-template-columns: minmax(0, 1fr); }
  .acc-item { grid-template-columns: 84px minmax(0, 1fr); }
  .acc-act { grid-column: 1 / -1; }
  .acc-act .btn { flex: 1; text-align: center; }
  .acc-head .btn { width: 100%; text-align: center; }
  .otable thead { display: none; }
  .otable, .otable tbody, .otable tr, .otable td { display: block; }
  .otable tr { padding: 10px 0; border-bottom: 1px solid var(--line); }
  .otable td { border: 0; padding: 2px 0; text-align: left !important; }
  .otable td::before { content: attr(data-label) ": "; color: var(--muted); }
}

/* ===== Trang đăng tin ===== */
.post-page { padding-bottom: 56px; }
.post-page svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.post-hero { background: linear-gradient(180deg, var(--surface), var(--bg)); border-bottom: 1px solid var(--line); padding: 16px 0 0; }
.ph-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 12px 0 18px; }
.ph-row h1 { margin: 0; font-family: var(--font-display); font-size: 28px; font-weight: 600; letter-spacing: -.01em; }
.ph-row p { margin: 4px 0 0; color: var(--muted); }
.ph-meter { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 10px 16px 10px 10px; max-width: 320px; }
.ph-meter > div:last-child { display: flex; flex-direction: column; font-size: 14px; }
.ph-meter small { color: var(--muted); font-size: 12.5px; }
.ring { --p: 0; width: 52px; height: 52px; flex: none; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--accent) calc(var(--p) * 1%), color-mix(in oklab, var(--accent) 14%, var(--surface)) 0); transition: --p .3s; }
.ring b { width: 40px; height: 40px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-size: 13px; font-weight: 700; color: var(--accent); }
.stepper { list-style: none; display: flex; gap: 6px; margin: 0; padding: 0; overflow-x: auto; scrollbar-width: none; }
.stepper::-webkit-scrollbar { display: none; }
.stepper li { flex: 1 1 0; min-width: max-content; }
.stepper a { display: flex; align-items: center; gap: 8px; padding: 10px 12px 12px; color: var(--muted); text-decoration: none; font-weight: 500; font-size: 14px; border-bottom: 3px solid transparent; }
.stepper a:hover { color: var(--fg); }
.st-num { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12.5px; font-weight: 700; border: 1.5px solid var(--line); background: var(--surface); flex: none; }
.st-num svg { width: 14px; height: 14px; display: none; stroke-width: 3; }
.stepper a.done .st-num { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.stepper a.done .st-num span { display: none; }
.stepper a.done .st-num svg { display: block; }
.stepper a.on { color: var(--fg); border-bottom-color: var(--accent); }
.stepper a.bad .st-num { border-color: var(--hot); color: var(--hot); }

.post-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; padding-top: 22px; }
.post-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.pcard { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px 22px; scroll-margin-top: 90px; }
.pcard > header { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 16px; }
.pcard > header h2 { margin: 0; font-family: var(--font-display); font-size: 18px; font-weight: 600; }
.pcard > header p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }
.pc-num { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-family: var(--font-display); }
.pcard.is-done .pc-num { background: var(--accent); color: var(--accent-fg); }
.pcard.has-err { border-color: color-mix(in oklab, var(--hot) 55%, var(--line)); }

.cat-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 10px; }
.cat-opt { position: relative; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 14px 8px 12px; border: 1.5px solid var(--line); border-radius: 14px; cursor: pointer; text-align: center; font-weight: 500; font-size: 13.5px; line-height: 1.3; transition: border-color .12s, background .12s, transform .12s; }
.cat-opt:hover { border-color: color-mix(in oklab, var(--c) 50%, var(--line)); }
.cat-opt input { position: absolute; opacity: 0; pointer-events: none; }
.co-ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in oklab, var(--c) 13%, var(--surface)); color: var(--c); }
.co-ico svg { width: 24px; height: 24px; stroke: var(--c); stroke-width: 1.8; }
.cat-opt:has(input:checked) { border-color: var(--c); background: color-mix(in oklab, var(--c) 7%, var(--surface)); box-shadow: 0 0 0 3px color-mix(in oklab, var(--c) 18%, transparent); }
.cat-opt:has(input:checked)::after { content: "✓"; position: absolute; top: 6px; right: 8px; width: 18px; height: 18px; border-radius: 50%; background: var(--c); color: #fff; font-size: 11px; display: grid; place-items: center; }
.cat-opt:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }

.pf { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; min-width: 0; }
.pf:last-child { margin-bottom: 0; }
.pf-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; font-weight: 600; font-size: 14px; }
.pf-top label { font-weight: 600; }
.pf-top i { color: var(--hot); font-style: normal; }
.pf-hint { color: var(--muted); font-size: 12.5px; }
.pf-hint a { color: var(--accent); }
.count { color: var(--muted); font-weight: 500; font-size: 12px; font-variant-numeric: tabular-nums; }
.count.warn { color: var(--hot); }
.pf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.post-page .field { background: var(--surface); border-radius: 10px; padding: 11px 12px; transition: border-color .12s, box-shadow .12s; }
.post-page .field:focus { box-shadow: 0 0 0 3px color-mix(in oklab, var(--accent) 16%, transparent); }
.post-page .field.invalid, .post-page .field[aria-invalid="true"] { border-color: var(--hot); }
.post-page .field.ok { border-color: color-mix(in oklab, var(--accent) 45%, var(--line)); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.add-chip { border: 1px dashed color-mix(in oklab, var(--accent) 50%, var(--line)); background: transparent; color: var(--accent); border-radius: 999px; padding: 5px 11px; font-size: 13px; font-weight: 500; cursor: pointer; }
.add-chip:hover { background: var(--accent-soft); border-style: solid; }
.add-chip.used { opacity: .45; }
.price-line { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.price-in { position: relative; flex: 1 1 180px; min-width: 0; }
.price-in .field { padding-right: 30px; font-weight: 600; font-variant-numeric: tabular-nums; }
.price-in em { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-style: normal; color: var(--muted); }
.price-line select.field { flex: 0 0 120px; width: 120px; }
.toggle { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 500; font-size: 14px; user-select: none; }
.toggle input { position: absolute; opacity: 0; }
.tg { width: 38px; height: 22px; border-radius: 999px; background: var(--line); position: relative; transition: background .15s; flex: none; }
.tg::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgb(0 0 0 / .2); transition: transform .15s; }
.toggle input:checked + .tg { background: var(--accent); }
.toggle input:checked + .tg::after { transform: translateX(16px); }
.toggle input:focus-visible + .tg { outline: 2px solid var(--accent); outline-offset: 2px; }
.post-page .field:disabled { opacity: .55; }

.drop { position: relative; border: 2px dashed var(--line); border-radius: 14px; background: var(--bg); transition: border-color .12s, background .12s; }
.drop input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 34px 16px; cursor: pointer; text-align: center; font-weight: 400; }
.drop-empty b { font-weight: 600; }
.drop-empty u { color: var(--accent); text-underline-offset: 3px; }
.drop-empty small { color: var(--muted); }
.dz-ico { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--surface); color: var(--accent); border: 1px solid var(--line); }
.dz-ico svg { width: 24px; height: 24px; }
.drop-prev { display: none; }
.drop.has-img { border-style: solid; background: var(--surface); }
.drop.has-img .drop-empty { display: none; }
.drop.has-img .drop-prev { display: block; }
.drop-prev img { display: block; width: 100%; max-height: 360px; object-fit: contain; background: color-mix(in oklab, var(--fg) 5%, var(--surface)); border-radius: 12px 12px 0 0; }
.dp-bar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; flex-wrap: wrap; }
.dp-bar span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13.5px; color: var(--muted); }
.btn.sm { padding: 6px 12px; font-size: 13.5px; }
.btn.lg { padding: 13px 26px; font-size: 16px; }
.perks-mini { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; color: var(--muted); }
.perks-mini li { display: flex; align-items: center; gap: 6px; }
.perks-mini svg { width: 15px; height: 15px; color: var(--accent); stroke-width: 2.5; }
.pcard-tier { display: flex; align-items: center; justify-content: space-between; gap: 14px; background: linear-gradient(90deg, var(--vip-soft), var(--surface)); }
.pcard-tier p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }
.post-page .plans legend { display: none; }
.post-submit { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 4px 4px 0; }
.post-submit .pf-hint { max-width: 420px; }
.ps-act { display: flex; gap: 10px; align-items: center; }
.ps-act [data-total-btn]:not(:empty) { margin-left: 8px; padding-left: 10px; border-left: 1px solid color-mix(in oklab, var(--accent-fg) 40%, transparent); font-weight: 500; }

.post-side { min-width: 0; }
.pside-sticky { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 14px; }
.pv { padding: 16px; }
.pv-head { display: flex; align-items: center; gap: 8px; font-size: 14px; margin-bottom: 12px; color: var(--muted); }
.pv-head svg { width: 18px; height: 18px; }
.pv-head b { color: var(--fg); }
.pv-card { --c: var(--accent); border: 1.5px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface); transition: border-color .2s, box-shadow .2s; }
.pv-card[data-tier=vip] { border-color: var(--vip); box-shadow: 0 0 0 3px color-mix(in oklab, var(--vip) 18%, transparent); background: linear-gradient(180deg, var(--surface) 60%, var(--vip-soft)); }
.pv-card[data-tier=featured] { border-color: var(--feat); }
.pv-thumb { position: relative; aspect-ratio: 16 / 10; background: color-mix(in oklab, var(--c) 14%, var(--surface)); display: grid; place-items: center; overflow: hidden; }
.pv-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pv-thumb img:not([src]), .pv-thumb img[src=""] { display: none; }
.pv-thumb.real img { object-fit: cover; }
.pv-ico { position: relative; width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: var(--surface); color: var(--c); box-shadow: 0 2px 8px rgb(0 0 0 / .08); }
.pv-ico:empty { display: none; }
.pv-thumb.has-def .pv-ico { position: absolute; width: 34px; height: 34px; border-radius: 10px; right: 8px; bottom: 8px; }
.pv-thumb.real .pv-ico { display: none; }
.pv-ico svg { width: 60%; height: 60%; stroke: var(--c); stroke-width: 1.8; }
.pv-badge { position: absolute; top: 8px; left: 8px; z-index: 1; }
.pv-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; }
.pv-cat { font-size: 12.5px; font-weight: 600; color: var(--c); display: flex; align-items: center; gap: 6px; }
.pv-cat::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pv-card h3 { margin: 0; font-size: 16px; line-height: 1.35; font-weight: 600; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pv-card h3.ph, .pv-desc.ph { color: var(--muted); font-weight: 400; }
.pv-desc { margin: 0; font-size: 13.5px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.pv-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12.5px; color: var(--muted); }
.pv-meta > span { display: inline-flex; align-items: center; gap: 4px; min-width: 0; }
.pv-meta svg { width: 13px; height: 13px; flex: none; }
.pv-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 4px; padding-top: 10px; border-top: 1px solid var(--line); }
.pv-foot .price { color: var(--price); font-size: 16px; }
.pv-foot .price small { color: var(--muted); font-weight: 500; font-size: 12.5px; }
.pv-call { display: inline-flex; align-items: center; gap: 6px; background: var(--accent); color: var(--accent-fg); border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.pv-call svg { width: 14px; height: 14px; }
.pv-check { padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.pv-check ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.pv-check li { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13.5px; }
.pv-check li svg { width: 18px; height: 18px; padding: 3px; border-radius: 50%; border: 1.5px solid var(--line); stroke: transparent; stroke-width: 3; flex: none; box-sizing: border-box; }
.pv-check li.ok { color: var(--fg); }
.pv-check li.ok svg { background: var(--accent); border-color: var(--accent); stroke: var(--accent-fg); }
.pv-total { display: flex; justify-content: space-between; gap: 10px; padding-top: 10px; border-top: 1px dashed var(--line); }
.pv-total span { color: var(--muted); }
.pv-total b { text-align: right; }
.post-bar { display: none; }

@media (max-width: 980px) {
  .post-grid { grid-template-columns: minmax(0, 1fr); }
  .post-side { order: -1; }
  .pside-sticky { position: static; }
  .pv-check { display: none; }
  .pv { padding: 12px; }
  .pv-card { display: grid; grid-template-columns: 120px minmax(0, 1fr); }
  .pv-thumb { aspect-ratio: auto; min-height: 100%; }
  .pv-desc, .pv-meta { display: none; }
  .pv-body { padding: 10px 12px; gap: 4px; }
  .pv-card h3 { font-size: 14.5px; }
  .pv-foot { margin-top: 2px; padding-top: 6px; }
  .pv-call { display: none; }
  .pv-head { margin-bottom: 8px; }
}
@media (max-width: 760px) {
  .post-page { padding-bottom: 96px; }
  .ph-row { flex-direction: column; align-items: stretch; gap: 12px; margin-bottom: 12px; }
  .ph-row h1 { font-size: 23px; }
  .ph-meter { max-width: none; }
  .stepper a { padding: 8px 8px 10px; font-size: 13px; gap: 6px; }
  .stepper li { flex: 0 0 auto; }
  .post-grid { padding-top: 14px; gap: 14px; }
  .post-page .wrap.post-grid { padding-left: 12px; padding-right: 12px; }
  .pcard { padding: 16px 14px; border-radius: 14px; }
  .pcard > header { gap: 10px; margin-bottom: 14px; }
  .pcard > header h2 { font-size: 16.5px; }
  .pc-num { width: 28px; height: 28px; border-radius: 8px; }
  .cat-pick { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .cat-opt { padding: 10px 4px; font-size: 12.5px; border-radius: 12px; }
  .co-ico { width: 38px; height: 38px; }
  .pf-row { grid-template-columns: minmax(0, 1fr); }
  .price-line select.field { flex: 1 1 100px; }
  .post-page .field { font-size: 16px; }
  .post-submit { flex-direction: column; align-items: stretch; }
  .post-submit .ps-act { display: none; }
  .pcard-tier { flex-direction: column; align-items: stretch; }
  .post-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: var(--surface); border-top: 1px solid var(--line); padding: 10px max(16px, env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left)); box-shadow: 0 -6px 20px rgb(0 0 0 / .06); }
  .post-bar > div { display: flex; flex-direction: column; min-width: 0; }
  .post-bar small { color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .post-bar b { font-size: 16px; }
  .post-bar .btn { padding: 12px 26px; font-size: 15.5px; }
  body:has(.post-bar) .float-contact { display: none; }
}
@media (max-width: 360px) { .cat-pick { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.post-page .pf-top label { display: inline; }
.post-page .toggle { flex-direction: row; }
.post-page .cat-opt { flex-direction: column; }
.post-page .add-chip, .post-page .chips { font-weight: 500; }
.post-grid > .post-side { align-self: stretch; }

/* ===== Trang Bảng giá ===== */
.pricing-page { padding-bottom: 56px; }
.pr-hero { background: linear-gradient(180deg, var(--surface), var(--bg)); border-bottom: 1px solid var(--line); padding: 16px 0 28px; margin-bottom: 24px; }
.pr-hero h1 { font-family: var(--font-display); font-size: 32px; font-weight: 600; margin: 14px 0 6px; }
.pr-hero p { margin: 0; color: var(--muted); max-width: 680px; font-size: 16px; }
.pr-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.pr-card { position: relative; background: var(--surface); border: 1.5px solid var(--line); border-radius: 18px; padding: 22px; display: flex; flex-direction: column; gap: 16px; }
.pr-card header h2 { margin: 0; font-family: var(--font-display); font-size: 19px; font-weight: 600; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pr-from { margin: 6px 0 0; color: var(--muted); }
.pr-from b { font-size: 26px; color: var(--fg); font-family: var(--font-display); }
.pr-featured { border-color: color-mix(in oklab, var(--feat) 55%, var(--line)); }
.pr-vip { border-color: var(--vip); background: linear-gradient(180deg, var(--vip-soft), var(--surface) 45%); box-shadow: 0 10px 30px color-mix(in oklab, var(--vip) 18%, transparent); }
.pr-ribbon { position: absolute; top: -12px; right: 18px; background: var(--vip); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.pr-perks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14.5px; }
.pr-perks li { display: flex; gap: 8px; align-items: flex-start; }
.pr-perks svg { width: 18px; height: 18px; flex: none; margin-top: 1px; fill: none; stroke: var(--accent); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.pr-tbl { width: 100%; border-collapse: collapse; font-size: 14px; margin-top: auto; }
.pr-tbl th { text-align: left; font-weight: 500; color: var(--muted); font-size: 12.5px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.pr-tbl td { padding: 9px 0; border-bottom: 1px dashed var(--line); font-variant-numeric: tabular-nums; }
.pr-tbl td b { color: var(--price); }
.pr-card .btn { text-align: center; padding: 12px; }
.pr-card:first-child .pr-perks { margin-bottom: auto; }
.pr-steps, .pr-faq { margin-top: 36px; }
.pr-steps h2, .pr-faq h2 { font-family: var(--font-display); font-size: 22px; font-weight: 600; margin: 0 0 14px; }
.pr-steps ol { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; counter-reset: s; }
.pr-steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.pr-steps li::before { content: counter(s); width: 30px; height: 30px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 700; margin-bottom: 6px; }
.pr-steps li span { color: var(--muted); }
.pr-faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin-bottom: 8px; }
.pr-faq summary { cursor: pointer; font-weight: 600; }
.pr-faq p { margin: 8px 0 0; color: var(--muted); }
@media (max-width: 900px) { .pr-cards { grid-template-columns: minmax(0, 1fr); } .pr-steps ol { grid-template-columns: 1fr 1fr; } .pr-vip { order: -1; } }
@media (max-width: 520px) { .pr-steps ol { grid-template-columns: minmax(0, 1fr); } .pr-hero h1 { font-size: 26px; } }

/* ===== Phân biệt tin thường / nổi bật / VIP ===== */
.r-tier, .c-tier { display: inline-flex; align-items: center; font-size: 11px; font-weight: 700; letter-spacing: .02em; padding: 2px 8px; border-radius: 999px; margin-left: 8px; }
.r-tier-vip, .c-tier-vip { background: linear-gradient(135deg, #f6c453, #d99a1e); color: #3d2600; }
.r-tier-featured, .c-tier-featured { background: var(--feat-soft); color: var(--feat); }
.c-tier { margin: 0 0 4px; align-self: flex-start; }
.ritem.tier-vip h3 { font-size: 1.08em; }
.ritem.tier-vip .price { font-size: 1.12em; }
.card.tier-vip { background: linear-gradient(180deg, var(--surface) 55%, var(--vip-soft)); }
.card.tier-vip .body h3 { font-weight: 700; }
.card.tier-featured .body { border-top: 3px solid var(--feat); }
.card.tier-vip .body { border-top: 3px solid #e2b04a; }
.tier-head { grid-column: 1 / -1; display: flex; align-items: baseline; gap: 10px; padding: 6px 2px 2px; margin-top: 6px; }
.tier-head:first-child { margin-top: 0; }
.tier-head b { font-family: var(--font-display); font-size: 15px; font-weight: 600; }
.tier-head span { color: var(--muted); font-size: 13px; }
.tier-head-vip b { color: var(--vip); }
.tier-head-featured b { color: var(--feat); }
.tier-head-normal { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 10px; }

.tier-sec { border-radius: 20px; padding: 20px; margin-bottom: 8px; }
.tier-sec .grid { padding-bottom: 0; }
.tier-sec .sec-head { align-items: center; }
.tier-sec .sec-head h2 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tier-sec .sec-head p { margin: 4px 0 0; color: var(--muted); font-size: 14px; }
.tier-sec-vip { background: linear-gradient(135deg, var(--vip-soft), color-mix(in oklab, var(--vip-soft) 40%, var(--surface))); border: 1px solid color-mix(in oklab, var(--vip) 35%, var(--line)); }
.tier-sec-featured { background: color-mix(in oklab, var(--feat-soft) 60%, var(--surface)); border: 1px solid color-mix(in oklab, var(--feat) 25%, var(--line)); }

.dv-tier { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: -4px 0 12px; padding: 9px 14px; border-radius: 12px; font-size: 13.5px; }
.dv-tier b { font-weight: 700; letter-spacing: .02em; }
.dv-tier-vip { background: linear-gradient(90deg, #f6c453, #f9dc95 70%, var(--vip-soft)); color: #3d2600; }
.dv-tier-featured { background: var(--feat-soft); color: var(--feat); }
.dv-tier-featured span { color: var(--fg); opacity: .75; }
.dv-vip .dv-gallery, .dv-vip .dv-head { border-color: #e2b04a; box-shadow: 0 0 0 1px #e2b04a; }
.dv-vip .dv-head { background: linear-gradient(180deg, var(--surface) 70%, var(--vip-soft)); }
.dv-featured .dv-gallery, .dv-featured .dv-head { border-color: color-mix(in oklab, var(--feat) 55%, var(--line)); }
.who-tier { margin: -20px -22px 0; padding: 9px 22px; border-radius: 13px 13px 0 0; font-size: 13px; font-weight: 700; letter-spacing: .02em; }
.who-vip { border-color: #e2b04a; box-shadow: 0 0 0 1px #e2b04a, 0 10px 26px rgb(183 121 31 / .14); }
.who-vip .who-tier { background: linear-gradient(90deg, #f6c453, #d99a1e); color: #3d2600; }
.who-featured { border-color: color-mix(in oklab, var(--feat) 55%, var(--line)); }
.who-featured .who-tier { background: var(--feat-soft); color: var(--feat); }
.owner-tier { font-size: 13.5px; padding: 10px 12px; border-radius: 10px; background: var(--bg); display: flex; flex-direction: column; gap: 4px; }
.callbar .cb-price .tier-badge { font-size: 10.5px; padding: 1px 7px; margin-right: 4px; vertical-align: 1px; }
.callbar-vip { border-top: 2px solid #e2b04a; }
@media (max-width: 760px) {
  .tier-sec { padding: 14px 12px; border-radius: 16px; margin-left: -4px; margin-right: -4px; }
  .r-tier { margin-left: 6px; }
  .who-tier { margin: -16px -16px 0; padding: 9px 16px; }
}
.ritem .tier-pin, .card .tier-pin, .dv-gallery .tier-pin { display: none; }
@media (max-width: 900px) { body:has(.callbar) .float-contact { bottom: calc(86px + env(safe-area-inset-bottom, 0px)); } }
