/* =========================================================
   Check Nhà — dashboard UI
   ========================================================= */

:root {
	--bg:           #f5f6f8;
	--surface:      #ffffff;
	--border:       #eef0f3;
	--border-2:     #e5e7eb;
	--text:         #1f2937;
	--text-2:       #4b5563; /* chú thích/mô tả — đậm hơn để khách dễ đọc (trước #6b7280). */
	--text-3:       #6b7280; /* ghi chú phụ — đậm hơn (trước #9ca3af). */

	--green:   #16a34a;  --green-bg:   #e7f7ee;
	--blue:    #2563eb;  --blue-bg:    #e8f0fe;
	--purple:  #7c3aed;  --purple-bg:  #f1ecfe;
	--orange:  #ea580c;  --orange-bg:  #fdeee1;
	--teal:    #0d9488;  --teal-bg:    #e3f6f3;
	--amber:   #d97706;  --amber-bg:   #fdf0db;
	--rose:    #e11d48;  --rose-bg:    #fde7ec;
	--indigo:  #4f46e5;  --indigo-bg:  #ebebfe;

	--brand:        #0f766e;
	--brand-bg:     #e3f6f3;
	--pro-1:        #0f766e;
	--pro-2:        #14b8a6;

	--radius:       16px;
	--radius-sm:    12px;
	--shadow:       0 1px 2px rgba(16,24,40,.04), 0 1px 3px rgba(16,24,40,.06);
	--shadow-md:    0 4px 16px rgba(16,24,40,.08);
	--sidebar-w:    248px;
	--font:         "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	font-family: var(--font);
	background: var(--bg);
	color: var(--text);
	font-size: 15px;
	line-height: 1.5;
	-webkit-font-smoothing: antialiased;
}

/* Chặn tràn ngang trên mobile (gạt sang ngang không còn lệch trang).
   Dùng clip (không phải hidden) để KHÔNG tạo scroll container mới → sticky topbar/sidebar vẫn chạy. */
html, body { overflow-x: clip; }

a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; font-weight: 700; }
ul { margin: 0; padding: 0; list-style: none; }
button { font-family: inherit; cursor: pointer; }

.icon { width: 20px; height: 20px; flex: 0 0 auto; }

/* ---------- App shell ---------- */
.app { display: flex; min-height: 100vh; }

/* ---------- Sidebar ---------- */
.sidebar {
	width: var(--sidebar-w);
	flex: 0 0 var(--sidebar-w);
	background: var(--surface);
	border-right: 1px solid var(--border);
	padding: 20px 16px;
	display: flex;
	flex-direction: column;
	gap: 4px;
	position: sticky;
	top: 0;
	height: 100vh;
	overflow-y: auto;
}

.brand { display: block; padding: 8px 6px 14px; }
.brand-img { width: 100%; height: auto; max-height: 140px; display: block; }
.brand-logo {
	width: 40px; height: 40px; border-radius: 12px;
	background: var(--brand-bg); color: var(--brand);
	display: grid; place-items: center;
}
.brand-logo .icon { width: 22px; height: 22px; }
.brand-logo.has-img { background: transparent; overflow: hidden; }
.brand-logo.has-img img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 12px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { font-size: 17px; color: var(--text); }
.brand-text small { font-size: 11px; color: var(--text-3); }

.nav { display: flex; flex-direction: column; gap: 2px; }
.nav-section {
	margin: 14px 8px 4px; font-size: 11px; font-weight: 600;
	letter-spacing: .06em; text-transform: uppercase; color: var(--text-3);
}
.nav-divider { height: 1px; background: var(--border); margin: 10px 8px; }

.nav-item {
	display: flex; align-items: center; gap: 11px;
	padding: 9px 10px; border-radius: 10px;
	color: var(--text-2); font-size: 14px; font-weight: 500;
	transition: background .15s, color .15s;
}
.nav-item .icon { width: 18px; height: 18px; color: var(--text-3); }
.nav-item:hover { background: #f7f8fa; color: var(--text); }
.nav-item:hover .icon { color: var(--text-2); }
.nav-item.is-active { background: var(--brand-bg); color: var(--brand); font-weight: 600; }
.nav-item.is-active .icon { color: var(--brand); }

/* PRO promo box */
.pro-box {
	margin-top: auto;
	background: linear-gradient(150deg, var(--pro-1), var(--pro-2));
	color: #fff; border-radius: var(--radius); padding: 16px;
}
.pro-box > strong { font-size: 15px; }
.pro-box ul { margin: 10px 0 14px; display: flex; flex-direction: column; gap: 7px; }
.pro-box li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: rgba(255,255,255,.92); }
.pro-box li .icon { width: 15px; height: 15px; color: #fff; }
.pro-box-btn {
	display: block; text-align: center; background: #fff; color: var(--pro-1);
	font-weight: 600; font-size: 13.5px; padding: 9px; border-radius: 10px;
}
.pro-box-btn:hover { background: #f3f1ff; }

.user { display: flex; align-items: center; gap: 10px; padding: 14px 6px 4px; margin-top: 12px; border-top: 1px solid var(--border); }
.user-avatar {
	width: 36px; height: 36px; border-radius: 50%;
	background: linear-gradient(135deg, #60a5fa, #6366f1); color: #fff;
	display: grid; place-items: center; font-size: 13px; font-weight: 600;
}
.user-meta { display: flex; flex-direction: column; gap: 2px; }
.user-meta strong { font-size: 13.5px; }
.badge { display: inline-block; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 6px; }
.badge-free { background: #f1f2f4; color: var(--text-2); width: max-content; }

/* ---------- Main ---------- */
.main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }

.topbar {
	position: sticky; top: 0; z-index: 20;
	display: flex; align-items: center; gap: 16px;
	padding: 14px 32px; background: var(--bg);
	border-bottom: 1px solid var(--border);
}
.searchbar {
	flex: 1 1 auto; max-width: 520px; min-width: 0;
	display: flex; align-items: center; gap: 10px;
	background: var(--surface); border: 1px solid var(--border-2);
	border-radius: 12px; padding: 0 14px; height: 44px;
}
.searchbar .icon { color: var(--text-3); width: 18px; height: 18px; }
.searchbar input { flex: 1; min-width: 0; width: 100%; border: none; outline: none; background: none; font-size: 14px; color: var(--text); }
.searchbar input::placeholder { color: var(--text-3); }

.topbar-right { display: flex; align-items: center; gap: 14px; margin-left: auto; }
/* Khu tài khoản trên topbar: nút Đăng ký (khách) / tên + Thoát (thành viên) */
.topbar-account { display: flex; align-items: center; gap: 10px; margin-left: auto; flex: 0 0 auto; }
.topbar-signup { height: 38px; padding: 0 16px; border: none; border-radius: 10px; background: #16a34a; color: #fff; font-size: 13.5px; font-weight: 700; cursor: pointer; box-shadow: 0 3px 10px rgba(22, 163, 74, .3); white-space: nowrap; }
.topbar-signup:hover { background: #15803d; }
.topbar-user { font-size: 13px; font-weight: 700; color: var(--text-1, #0f172a); white-space: nowrap; }
.topbar-logout { font-size: 12.5px; color: var(--text-3, #94a3b8); text-decoration: none; white-space: nowrap; }
.topbar-logout:hover { color: #dc2626; }
.topbar-signup .ts-short { display: none; }
@media (max-width: 640px) {
	.topbar-signup { padding: 0 12px; font-size: 12.5px; height: 36px; }
	.topbar-signup .ts-full { display: none; }
	.topbar-signup .ts-short { display: inline; }
	.topbar-user { max-width: 110px; overflow: hidden; text-overflow: ellipsis; }
}
.icon-btn {
	position: relative; width: 42px; height: 42px; border-radius: 12px;
	border: 1px solid var(--border-2); background: var(--surface); color: var(--text-2);
	display: grid; place-items: center;
}
.icon-btn:hover { background: #f7f8fa; }
.badge-dot {
	position: absolute; top: -5px; right: -5px; min-width: 18px; height: 18px;
	padding: 0 4px; border-radius: 9px; background: #ef4444; color: #fff;
	font-size: 11px; font-weight: 700; display: grid; place-items: center; border: 2px solid var(--bg);
}
.btn-pro {
	display: inline-flex; align-items: center; gap: 7px;
	background: linear-gradient(135deg, var(--pro-1), var(--pro-2)); color: #fff;
	font-weight: 600; font-size: 14px; padding: 11px 18px; border-radius: 12px;
	box-shadow: 0 6px 16px rgba(15,118,110,.32);
}
.btn-pro:hover { filter: brightness(1.05); }
.btn-pro .icon { width: 16px; height: 16px; fill: #fff; stroke: #fff; }

.content { padding: 32px; max-width: 1400px; width: 100%; margin: 0 auto; }

/* ---------- Hero ---------- */
/* ---------- Hero CTA banner ---------- */
.hero-cta {
	display: flex; align-items: center; gap: 22px; margin-bottom: 30px;
	background: linear-gradient(135deg, #f0fdf4, var(--surface) 60%);
	border: 1px solid var(--green-bg); border-radius: var(--radius);
	padding: 24px 26px; box-shadow: var(--shadow);
}
.hero-cta-ic {
	flex: none; width: 56px; height: 56px; border-radius: 16px;
	display: inline-flex; align-items: center; justify-content: center;
	background: var(--green-bg); color: var(--green);
}
.hero-cta-ic .icon { width: 28px; height: 28px; }
.hero-cta-ic.has-img { width: auto; height: auto; min-width: 0; background: transparent; border-radius: 0; padding: 0; }
.hero-cta-ic.has-img img { height: 76px; width: auto; max-width: 210px; object-fit: contain; display: block; }
.hero-cta-text { flex: 1; min-width: 0; }
.hero-eyebrow {
	display: block; font-size: 12px; font-weight: 700; letter-spacing: .06em;
	text-transform: uppercase; color: var(--green); margin-bottom: 6px;
}
.hero-cta h1 { font-size: 26px; line-height: 1.25; letter-spacing: -.01em; }
.hero-cta .hl { color: var(--green); }
.hero-cta p { margin: 8px 0 0; color: var(--text-2); font-size: 15px; }
.hero-cta-btn {
	flex: none; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
	background: linear-gradient(135deg, #22c55e, var(--green)); color: #fff;
	font-weight: 700; font-size: 15px; padding: 14px 24px; border-radius: 999px;
	box-shadow: 0 8px 20px rgba(22,163,74,.30);
	transition: transform .15s, filter .15s;
}
.hero-cta-btn .icon { width: 18px; height: 18px; transition: transform .15s; }
.hero-cta-btn:hover { filter: brightness(1.04); transform: translateY(-1px); }
.hero-cta-btn:hover .icon { transform: translateX(3px); }

/* Pulse "kích thích click" — nhẹ nhàng, dễ chịu */
.hero-cta-btn.pulse { animation: cn-pulse 2.2s ease-in-out infinite; }
@keyframes cn-pulse {
	0%, 100% { box-shadow: 0 8px 20px rgba(22,163,74,.30), 0 0 0 0 rgba(22,163,74,.40); }
	50%      { box-shadow: 0 10px 24px rgba(22,163,74,.40), 0 0 0 10px rgba(22,163,74,0); }
}
@media (prefers-reduced-motion: reduce) {
	.hero-cta-btn.pulse { animation: none; }
}

/* ---------- Tool cards ---------- */
.tools {
	display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 18px;
	margin-bottom: 30px;
}
.tool-card {
	background: var(--surface); border: 1px solid var(--border);
	border-radius: var(--radius); padding: 22px 18px; text-align: center;
	box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center;
	transition: transform .15s, box-shadow .15s;
}
.tool-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.tool-icon {
	width: 60px; height: 60px; border-radius: 16px;
	display: grid; place-items: center; margin-bottom: 14px;
	background: var(--accent-bg); color: var(--accent);
}
.tool-icon .icon { width: 28px; height: 28px; }
.tool-card h3 { font-size: 16px; color: var(--accent); }
.tool-card p { margin: 8px 0 16px; font-size: 13px; color: var(--text-2); flex: 1; }
.tool-cta {
	display: block; width: 100%; padding: 11px; border-radius: 10px;
	background: var(--accent-bg); color: var(--accent); font-weight: 600; font-size: 13.5px;
	transition: filter .15s;
}
.tool-cta:hover { filter: brightness(.97); }

/* accent helpers */
.accent-green  { --accent: var(--green);  --accent-bg: var(--green-bg); }
.accent-blue   { --accent: var(--blue);   --accent-bg: var(--blue-bg); }
.accent-purple { --accent: var(--purple); --accent-bg: var(--purple-bg); }
.accent-orange { --accent: var(--orange); --accent-bg: var(--orange-bg); }
.accent-teal   { --accent: var(--teal);   --accent-bg: var(--teal-bg); }
.accent-amber  { --accent: var(--amber);  --accent-bg: var(--amber-bg); }
.accent-rose   { --accent: var(--rose);   --accent-bg: var(--rose-bg); }
.accent-indigo { --accent: var(--indigo); --accent-bg: var(--indigo-bg); }

/* ---------- Panels ---------- */
.panel {
	background: var(--surface); border: 1px solid var(--border);
	border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow);
}
.panel-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.panel-head h2 { font-size: 18px; }
.link-all { color: var(--blue); font-size: 13.5px; font-weight: 600; }
.link-all:hover { text-decoration: underline; }

.dash-row { display: grid; grid-template-columns: minmax(0,1fr) 320px; gap: 22px; margin-bottom: 30px; }

/* ---------- Project cards ---------- */
.project-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.project-card { border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; background: var(--surface); transition: box-shadow .15s; }
.project-card:hover { box-shadow: var(--shadow-md); }
.project-thumb { position: relative; height: 130px; display: grid; place-items: center; color: rgba(255,255,255,.85); overflow: hidden; }
.project-thumb .thumb-ic { width: 34px; height: 34px; }
.project-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.project-thumb.is-checking { background: linear-gradient(135deg, #e0e7ff, #c7d2fe); color: var(--brand); }
.thumb-loader { display: flex; flex-direction: column; align-items: center; gap: 9px; }
.thumb-spinner { width: 30px; height: 30px; border: 3px solid rgba(99,102,241,.28); border-top-color: var(--brand); border-radius: 50%; animation: cn-spin .8s linear infinite; }
.thumb-loading-text { font-size: 12.5px; font-weight: 600; color: var(--brand); }
@keyframes cn-spin { to { transform: rotate(360deg); } }
.tone-warm { background: linear-gradient(135deg, #d9a679, #b27d50); }
.tone-cool { background: linear-gradient(135deg, #aab6c4, #7e8ea1); }
.tone-dark { background: linear-gradient(135deg, #4b5563, #2d333d); }
.project-body { padding: 14px; }
.project-body h3 { font-size: 14.5px; }
.project-sub { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 8px 0 12px; }
.project-sub > span:first-child { font-size: 12px; color: var(--text-3); }
.status { font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 20px; white-space: nowrap; }
.status-done { background: var(--green-bg); color: var(--green); }
.status-progress { background: var(--orange-bg); color: var(--orange); }
.project-stats { display: flex; gap: 16px; padding-top: 12px; border-top: 1px solid var(--border); }
.project-stats span { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--text-2); }
.project-stats .icon { width: 15px; height: 15px; color: var(--text-3); }

/* ---------- Insights ---------- */
.insight-list { display: flex; flex-direction: column; }
.insight-list li {
	display: grid; grid-template-columns: 38px auto 1fr; align-items: center; gap: 12px;
	padding: 13px 0; border-bottom: 1px solid var(--border);
}
.insight-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-bg); color: var(--accent); }
.insight-icon .icon { width: 19px; height: 19px; }
.insight-value { font-size: 20px; font-weight: 700; }
.insight-label { font-size: 13px; color: var(--text-2); }
.insight-total { margin: 16px 0 0; font-size: 13.5px; color: var(--text-2); }
.insight-total strong { color: var(--text); }

/* ---------- Library ---------- */
.library-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.library-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px; background: #fbfbfc; transition: box-shadow .15s, transform .15s; }
.library-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); background: #fff; }
.library-card h3 { font-size: 14px; }
.library-card p { margin: 8px 0 14px; font-size: 12.5px; color: var(--text-2); min-height: 50px; }
.library-count { font-size: 13.5px; font-weight: 700; color: var(--orange); }

/* ---------- Mobile sidebar toggle ---------- */
.sidebar-toggle {
	display: none; position: fixed; top: 16px; left: 16px; z-index: 60;
	width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--border-2);
	background: var(--surface); flex-direction: column; gap: 4px; align-items: center; justify-content: center;
}
.sidebar-toggle span { width: 20px; height: 2px; background: var(--text); border-radius: 2px; }
.sidebar-backdrop { display: none; position: fixed; inset: 0; background: rgba(15,23,42,.45); z-index: 40; }
body.nav-open .sidebar-backdrop { display: block; }

/* ---------- Responsive ---------- */
@media (max-width: 1200px) {
	.tools, .library-grid { grid-template-columns: repeat(3, 1fr); }
	.dash-row { grid-template-columns: 1fr; }
	.insights { order: -1; }
}
@media (max-width: 900px) {
	.content, .topbar { padding-left: 20px; padding-right: 20px; }
	.project-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
	.sidebar-toggle { display: flex; }
	.sidebar {
		position: fixed; left: 0; top: 0; z-index: 50;
		transform: translateX(-100%); transition: transform .25s ease;
		box-shadow: var(--shadow-md);
	}
	body.nav-open .sidebar { transform: translateX(0); }
	.topbar { padding-left: 72px; }
	.tools, .library-grid { grid-template-columns: repeat(2, 1fr); }
	.hero-cta { flex-direction: column; align-items: center; text-align: center; gap: 16px; padding: 20px; }
	.hero-cta h1 { font-size: 22px; }
	.hero-cta-btn { width: 100%; justify-content: center; }
	.hero-cta-ic.has-img { width: 100%; align-self: center; }
	.hero-cta-ic.has-img img { width: 100%; max-width: 300px; height: auto; margin: 0 auto; }

	/* Check báo giá: nén + đưa form "Mở khoá" lên ngay sau bảng điểm để thấy sớm */
	.cn-result { gap: 14px; }
	.cn-result .report-cta { order: 1; }
	.cn-result .report-lockwrap { order: 2; }
	.result-card { padding: 14px; }
	.score-hero { gap: 12px; padding-bottom: 12px; margin-bottom: 12px; }
	.score-hero-num strong { font-size: 34px; }
	.score-grid { grid-template-columns: repeat(2, 1fr); gap: 9px; }
	.score-card { padding: 10px; gap: 9px; }
	.score-ic { width: 34px; height: 34px; }
	.score-ic .icon { width: 17px; height: 17px; }
	.score-val { font-size: 17px; }
	.score-label { font-size: 11.5px; }
	.report-intro { padding: 12px 14px; }
	.report-intro h2 { font-size: 15px; }
	.report-locked.is-locked { max-height: 320px; }
	.report-gate-card { padding: 16px; }
}
@media (max-width: 560px) {
	.tools { grid-template-columns: repeat(2, 1fr); gap: 12px; }
	.library-grid, .project-grid { grid-template-columns: 1fr; }
	.tool-card { padding: 16px 12px; }
	.tool-icon { width: 50px; height: 50px; border-radius: 14px; margin-bottom: 10px; }
	.tool-icon .icon { width: 24px; height: 24px; }
	.tool-card h3 { font-size: 14.5px; }
	.tool-card p { font-size: 12px; margin: 6px 0 12px; }
	.tool-cta { padding: 9px; font-size: 12.5px; }
	.score-grid { grid-template-columns: repeat(2, 1fr); gap: 9px; }
	.score-card { padding: 10px 9px; gap: 9px; }
	.score-ic { width: 34px; height: 34px; border-radius: 10px; }
	.score-ic .icon { width: 17px; height: 17px; }
	.score-val { font-size: 16px; }
	.score-label { font-size: 11px; }
	.analysis-grid, .material-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
	.cat-cols { grid-template-columns: 1fr; gap: 10px; }
	.cat-score { font-size: 16px; }
	.btn-pro span, .btn-pro { font-size: 0; gap: 0; padding: 11px; }
	.btn-pro .icon { width: 18px; height: 18px; }
}

/* Trang chủ: các panel xếp dọc cần khoảng cách đều (tránh dính sát nhau) */
.content > .panel { margin-bottom: 30px; }
.content > .panel:last-child { margin-bottom: 0; }

/* =========================================================
   Trang chủ — tối ưu gọn gàng, ngăn nắp trên mobile (≤560)
   ========================================================= */
@media (max-width: 560px) {
	.content { padding: 14px; }

	/* Khoảng cách giữa các khối: đều & gọn, bỏ ô trống thừa */
	.hero-cta, .tools, .dash-row { margin-bottom: 14px; }
	.dash-row { gap: 14px; }
	.content > .panel { margin-bottom: 14px; }
	.panel { padding: 15px 13px; }
	.panel-head { margin-bottom: 12px; }
	.panel-head h2 { font-size: 16px; }

	/* Hero: nén lại, logo nhỏ gọn */
	.hero-cta { padding: 16px 14px; gap: 12px; }
	.hero-cta h1 { font-size: 19px; line-height: 1.3; }
	.hero-cta p { font-size: 13.5px; margin-top: 6px; }
	.hero-cta-ic.has-img img { max-width: 150px; }
	.hero-cta-btn { padding: 12px 20px; font-size: 14px; }

	/* Công cụ: 2 cột khít nhau */
	.tools { gap: 10px; }
	.tool-card { padding: 14px 11px; }

	/* Thư viện lỗi: 2 cột chip gọn — ẩn mô tả + bỏ ô trống min-height */
	.library-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
	.library-card { padding: 12px 12px 13px; }
	.library-card p { display: none; }
	.library-card h3 { font-size: 13.5px; line-height: 1.35; }
	.library-count { font-size: 13px; }

	/* Hoạt động gần đây: ảnh tài liệu thấp lại cho gọn */
	.act-doc-img { max-height: 150px; }
	.act-doc { margin: 4px 0 12px; }

	/* Tin tức: lưới gọn */
	.news-home .news-grid { gap: 12px; }

	/* Giới thiệu (SEO): cỡ chữ vừa phải, dễ đọc */
	.home-seo h2 { font-size: 16.5px; }
	.home-seo-subh { margin-top: 18px !important; }
	.home-seo-body p { font-size: 13.5px; line-height: 1.62; margin-bottom: 10px; }
}

/* =========================================================
   Trang module (views)
   ========================================================= */

.tool-card { color: inherit; }

/* Breadcrumb + page header */
.breadcrumb { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-3); margin-bottom: 14px; }
.breadcrumb a { color: var(--text-2); }
.breadcrumb a:hover { color: var(--text); }
.breadcrumb .icon { width: 14px; height: 14px; }

.page-head { display: flex; align-items: center; gap: 16px; margin-bottom: 24px; }
.page-icon { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: var(--accent-bg); color: var(--accent); flex: 0 0 auto; }
.page-icon .icon { width: 26px; height: 26px; }
.page-head-text { flex: 1; min-width: 0; }
.page-head-text h1 { font-size: 24px; }
.page-head-text p { margin: 6px 0 0; color: var(--text-2); font-size: 14px; }
.badge-free-lg { align-self: flex-start; background: var(--green-bg); color: var(--green); font-size: 12px; font-weight: 700; padding: 5px 12px; border-radius: 20px; white-space: nowrap; }

/* Layout 2 cột check */
.check-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; align-items: start; }
.check-main { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.check-side { display: flex; flex-direction: column; gap: 18px; }

.side-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.side-card h3 { font-size: 15px; margin-bottom: 12px; }
.side-text { font-size: 13px; color: var(--text-2); margin: 0; }
.tick-list { display: flex; flex-direction: column; gap: 9px; }
.tick-list li { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--text-2); }
.tick-list .icon { width: 16px; height: 16px; color: var(--green); flex: 0 0 auto; margin-top: 1px; }

.process-list { display: flex; flex-direction: column; gap: 10px; counter-reset: step; }
.process-list li { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--text-2); }
.process-no { width: 22px; height: 22px; border-radius: 50%; background: var(--brand-bg); color: var(--brand); font-size: 12px; font-weight: 700; display: grid; place-items: center; flex: 0 0 auto; }

/* Dropzone */
.dropzone {
	background: var(--surface); border: 2px dashed var(--border-2); border-radius: var(--radius);
	padding: 36px 24px; text-align: center; transition: border-color .15s, background .15s;
}
.dropzone.is-drag { border-color: var(--brand); background: var(--brand-bg); }
.dropzone-icon { width: 56px; height: 56px; border-radius: 50%; background: var(--brand-bg); color: var(--brand); display: grid; place-items: center; margin: 0 auto 14px; }
.dropzone-icon .icon { width: 26px; height: 26px; }
.dropzone-title { font-size: 16px; font-weight: 600; margin: 0; }
.dropzone-sub { font-size: 13px; color: var(--text-3); margin: 6px 0 16px; }
.dropzone-files { font-size: 13px; color: var(--brand); font-weight: 600; margin: 12px 0 0; }
.dropzone-note { font-size: 12px; color: var(--text-3); margin: 14px 0 0; }

/* Hướng dẫn chuẩn bị dữ liệu + kết quả mẫu (demo) */
.prep-guide { border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius-sm); padding: 16px 18px; margin: 0 0 18px; box-shadow: var(--shadow); }
.prep-guide-head { display: flex; align-items: flex-start; gap: 12px; }
.prep-guide-ic { width: 38px; height: 38px; border-radius: 10px; background: var(--brand-bg); color: var(--brand); display: grid; place-items: center; flex: 0 0 auto; }
.prep-guide-ic .icon { width: 20px; height: 20px; }
.prep-guide-text { flex: 1 1 auto; min-width: 0; }
.prep-guide-text h3 { margin: 0; font-size: 15px; font-weight: 700; }
.prep-guide-text p { margin: 2px 0 0; font-size: 13px; color: var(--text-3); }
.prep-demo-btn { flex: 0 0 auto; white-space: nowrap; }
.prep-guide-list { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; }
.prep-guide-list li { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; color: var(--text); }
.prep-guide-list .icon { width: 16px; height: 16px; color: var(--green); flex: 0 0 auto; margin-top: 2px; }
.cn-demo { margin-top: 18px; border: 1px dashed #cbd5e1; border-radius: var(--radius); padding: 16px; background: #fbfdff; display: flex; flex-direction: column; gap: 22px; }
.cn-demo-flag { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--amber); background: var(--amber-bg); border-radius: 10px; padding: 10px 12px; margin: 0; }
.cn-demo-flag .icon { width: 18px; height: 18px; flex: 0 0 auto; margin-top: 1px; }
.cn-demo-flag strong { color: #92400e; }
@media (max-width: 640px) { .prep-guide-head { flex-wrap: wrap; } .prep-demo-btn { width: 100%; justify-content: center; } }

.btn-primary {
	display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
	background: linear-gradient(135deg, #0f766e, #14b8a6); color: #fff;
	font-weight: 600; font-size: 14px; padding: 11px 20px; border: none; border-radius: 12px;
	box-shadow: 0 6px 16px rgba(15,118,110,.28);
}
.btn-primary:hover { filter: brightness(1.05); }
.btn-primary .icon { width: 17px; height: 17px; }

/* Result cards */
.result-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.section-title { font-size: 16px; margin-bottom: 16px; }
.result-empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 24px; color: var(--text-3); }
.result-empty .icon { width: 30px; height: 30px; }
.result-empty p { margin: 0; font-size: 13.5px; max-width: 440px; }
.result-hint { font-size: 13px; color: var(--text-3); margin: 14px 0 0; }

/* Score grid */
.score-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 14px; }
.score-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; display: flex; flex-direction: row; align-items: center; gap: 12px; background: #fbfbfc; }
.score-ic { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; flex: 0 0 auto; }
.score-ic .icon { width: 21px; height: 21px; }
.score-body { display: flex; flex-direction: column; min-width: 0; }
.score-val { font-size: 22px; font-weight: 700; color: var(--text-2); line-height: 1.1; }
.score-val small { font-size: 12px; color: var(--text-3); font-weight: 500; }
.score-label { font-size: 12.5px; color: var(--text-2); margin-top: 2px; }
.score-card.tone-good .score-ic { background: var(--green-bg); color: var(--green); }
.score-card.tone-warn .score-ic { background: var(--amber-bg); color: var(--amber); }
.score-card.tone-risk .score-ic { background: var(--rose-bg); color: var(--rose); }

/* Tables */
.table-wrap { overflow-x: auto; }
.compare-table, .history-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.compare-table th, .compare-table td, .history-table th, .history-table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.compare-table thead th, .history-table thead th { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); background: #fafbfc; }
.compare-table tbody th { font-weight: 600; }
.compare-table tbody th.crit-cell { white-space: nowrap; }
.compare-table .crit-inner { display: inline-flex; align-items: center; gap: 9px; }
.compare-table tbody th .cell-ic { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 7px; background: var(--brand-bg); color: var(--brand); vertical-align: middle; flex: 0 0 auto; }
.compare-table tbody th .cell-ic .icon { width: 14px; height: 14px; }
.compare-table .cell-label { line-height: 1.3; }
.compare-table td { color: var(--text-3); }
/* Màu theo cột: đơn vị A xanh dương, B xanh lá... — nhận xét AI đỏ */
.compare-table .u-0 { color: var(--blue); font-weight: 500; }
.compare-table .u-1 { color: var(--green); font-weight: 500; }
.compare-table .u-2 { color: var(--purple); font-weight: 500; }
.compare-table .u-3 { color: var(--orange); font-weight: 500; }
.compare-table .u-4 { color: var(--teal); font-weight: 500; }
.compare-table thead th.u-0, .compare-table thead th.u-1, .compare-table thead th.u-2, .compare-table thead th.u-3, .compare-table thead th.u-4, .compare-table thead th.note-col { font-weight: 700; }
.compare-table .note-col { color: #dc2626; }
.history-tool { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--brand); }
.history-tool .icon { width: 16px; height: 16px; }

/* Analysis grid */
.analysis-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.analysis-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px; background: #fbfbfc; }
.analysis-ic { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--brand-bg); color: var(--brand); }
.analysis-ic .icon { width: 20px; height: 20px; }
.analysis-card h3 { font-size: 14.5px; margin: 12px 0 6px; }
.analysis-card p { font-size: 12.5px; color: var(--text-2); margin: 0 0 12px; }
.analysis-state { font-size: 11.5px; font-weight: 600; color: var(--text-3); background: #f1f2f4; padding: 3px 10px; border-radius: 20px; }

/* Checklist */
.checklist { display: flex; flex-direction: column; gap: 10px; }
.checklist-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: #fbfbfc; }
.checklist-ic { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: var(--brand-bg); color: var(--brand); flex: 0 0 auto; }
.checklist-ic .icon { width: 18px; height: 18px; }
.checklist-item div { flex: 1; display: flex; flex-direction: column; }
.checklist-item strong { font-size: 14px; }
.checklist-item span { font-size: 12.5px; color: var(--text-2); }
.checklist-state { font-size: 18px; color: var(--text-3); font-weight: 700; }

/* Material grid */
.material-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; }
.material-card { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 16px; background: #fbfbfc; }
.material-tag { display: inline-block; font-weight: 700; font-size: 13px; color: var(--teal); background: var(--teal-bg); padding: 4px 12px; border-radius: 8px; margin-bottom: 10px; }
.material-card p { font-size: 12.5px; color: var(--text-2); margin: 0; }

/* Error library */
.errlib-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.errlib-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.errlib-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.errlib-ic { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; background: var(--accent-bg); color: var(--accent); }
.errlib-ic .icon { width: 21px; height: 21px; }
.errlib-head h3 { font-size: 15.5px; }
.errlib-list { display: flex; flex-direction: column; gap: 10px; }
.errlib-list li { display: flex; align-items: center; gap: 9px; font-size: 13.5px; color: var(--text-2); }
.errlib-list .icon { width: 16px; height: 16px; color: var(--accent); flex: 0 0 auto; }

/* Chat (Hỏi AI) */
.chat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 16px; }
.chat-thread { display: flex; flex-direction: column; gap: 14px; min-height: 220px; }
.chat-msg { display: flex; gap: 10px; max-width: 80%; }
.chat-ai { align-self: flex-start; }
.chat-user { align-self: flex-end; flex-direction: row-reverse; }
.chat-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-bg); color: var(--brand); display: grid; place-items: center; flex: 0 0 auto; }
.chat-avatar .icon { width: 18px; height: 18px; }
.chat-bubble { background: #f4f5f7; border-radius: 14px; padding: 11px 15px; font-size: 14px; line-height: 1.55; }
.chat-user .chat-bubble { background: var(--brand); color: #fff; }
.chat-suggest { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { background: var(--surface); border: 1px solid var(--border-2); border-radius: 20px; padding: 8px 14px; font-size: 13px; color: var(--text-2); cursor: pointer; transition: background .15s, border-color .15s; }
.chip:hover { background: var(--brand-bg); border-color: var(--brand); color: var(--brand); }
.chat-input { display: flex; gap: 10px; }
.chat-input input { flex: 1; border: 1px solid var(--border-2); border-radius: 12px; padding: 0 16px; height: 46px; font-size: 14px; outline: none; }
.chat-input input:focus { border-color: var(--brand); }
.chat-note { font-size: 12px; color: var(--text-3); margin: 0; text-align: center; }

/* Saved questions */
.saved-list { display: flex; flex-direction: column; }
.saved-list li { display: flex; align-items: center; gap: 12px; padding: 14px 4px; border-bottom: 1px solid var(--border); }
.saved-list li:last-child { border-bottom: 0; }
.saved-ic { width: 34px; height: 34px; border-radius: 10px; background: var(--purple-bg); color: var(--purple); display: grid; place-items: center; flex: 0 0 auto; }
.saved-ic .icon { width: 17px; height: 17px; }
.saved-q { flex: 1; font-size: 14px; }
.saved-go { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 600; color: var(--brand); white-space: nowrap; }
.saved-go .icon { width: 15px; height: 15px; }

/* Toolbar dự án */
.projects-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.projects-count { font-size: 13.5px; color: var(--text-2); }
.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin: 26px 0 8px; }
.pagination .page-num, .pagination .page-btn { display: inline-flex; align-items: center; gap: 4px; min-width: 38px; height: 38px; padding: 0 12px; justify-content: center; border: 1px solid var(--border-2); border-radius: 10px; background: #fff; color: var(--text); font-size: 14px; font-weight: 600; text-decoration: none; }
.pagination a.page-num:hover, .pagination a.page-btn:hover { border-color: var(--brand); color: var(--brand); }
.pagination .page-num.is-current { background: var(--brand); border-color: var(--brand); color: #fff; }
.pagination .page-btn .icon { width: 15px; height: 15px; }
.pagination .page-btn[rel="prev"] .icon { transform: rotate(180deg); }
.pagination .is-disabled { opacity: .45; pointer-events: none; }
.project-grid-wide { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

@media (max-width: 1100px) {
	.check-layout { grid-template-columns: 1fr; }
	.check-side { flex-direction: row; flex-wrap: wrap; }
	.check-side > * { flex: 1 1 240px; }
}
@media (max-width: 600px) {
	.page-head { flex-wrap: wrap; }
	.check-side { flex-direction: column; }
	.chat-msg { max-width: 95%; }
}

/* =========================================================
   Kết quả demo (spec) — điểm, cảnh báo, CTA, thư viện, PRO
   ========================================================= */

/* Nhãn demo */
.demo-badge { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #5b6470; background: var(--indigo-bg); border: 1px solid #e0e0fb; border-radius: 10px; padding: 9px 14px; margin: 0; }
.demo-badge .icon { width: 16px; height: 16px; color: var(--indigo); flex: 0 0 auto; }

/* Tổng điểm + rủi ro */
.score-hero { display: flex; align-items: center; gap: 20px; padding-bottom: 18px; margin-bottom: 18px; border-bottom: 1px solid var(--border); }
.result-card > .score-hero:only-child { padding-bottom: 0; margin-bottom: 0; border-bottom: 0; }
.score-hero-num { display: flex; align-items: baseline; gap: 2px; }
.score-hero-num strong { font-size: 44px; line-height: 1; }
.score-hero-num span { font-size: 18px; color: var(--text-3); }
.score-hero-meta { display: flex; flex-direction: column; gap: 8px; }
.score-hero-label { font-size: 13px; color: var(--text-3); }
.risk-badge, .sev-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; padding: 5px 12px; border-radius: 20px; width: fit-content; }
.risk-badge .icon { width: 15px; height: 15px; }
.risk-badge.tone-good, .sev-badge.tone-good { background: var(--green-bg); color: var(--green); }
.risk-badge.tone-warn, .sev-badge.tone-warn { background: var(--amber-bg); color: var(--amber); }
.risk-badge.tone-risk, .sev-badge.tone-risk { background: var(--rose-bg); color: var(--rose); }

/* Danh sách cảnh báo chi tiết */
.warning-list { list-style: none; display: flex; flex-direction: column; gap: 14px; padding: 0; margin: 0; }
.warn-item { display: block; border: 1px solid var(--border); border-left: 4px solid var(--border-2); border-radius: var(--radius-sm); padding: 16px 18px; background: #fff; }
.warn-item.lvl-cao { border-left-color: #dc2626; }
.warn-item.lvl-tb { border-left-color: var(--amber); }
.warn-item.lvl-thap { border-left-color: #ca8a04; }
.warn-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.warn-muc { font-size: 12px; font-weight: 700; color: #374151; background: #eef0f3; padding: 3px 11px; border-radius: 20px; }
.warn-lvl { font-size: 11.5px; font-weight: 700; padding: 3px 11px; border-radius: 20px; }
.warn-lvl.lvl-cao { background: #fee2e2; color: #dc2626; }
.warn-lvl.lvl-tb { background: var(--amber-bg); color: var(--amber); }
.warn-lvl.lvl-thap { background: #fef9c3; color: #a16207; }
.warn-quote { font-style: italic; color: var(--text-2); background: #f6f7f9; border-radius: 8px; padding: 9px 12px; margin: 0 0 12px; font-size: 13px; line-height: 1.5; }
.warn-field { display: block; font-size: 13.5px; color: #b91c1c; margin: 0 0 9px; line-height: 1.55; }
.warn-field .warn-label { font-weight: 700; color: #dc2626; }
.warn-ask { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; color: #075985; background: #e0f2fe; border-radius: 8px; padding: 11px 13px; margin: 12px 0 0; line-height: 1.55; }
.warn-ask-ic { flex: 0 0 auto; }
.warn-ask-ic .icon { display: block; width: 16px; height: 16px; margin-top: 1px; color: #0284c7; }
.warn-ask-body { flex: 1 1 auto; min-width: 0; }
.warn-ask-label { font-weight: 700; color: #0284c7; }
.tick-list-lg li { font-size: 14px; align-items: flex-start; }
.tick-list-lg .icon { margin-top: 2px; }

/* Check báo giá — phân tích chi tiết theo hạng mục */
.cat-list { display: flex; flex-direction: column; gap: 16px; }
.cat-block { border: 1px solid var(--border); border-left: 4px solid var(--border-2); border-radius: var(--radius-sm); padding: 16px 18px; background: #fff; }
.cat-block.tone-good { border-left-color: var(--green); }
.cat-block.tone-warn { border-left-color: var(--amber); }
.cat-block.tone-risk { border-left-color: #dc2626; }
.cat-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.cat-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: #f1f2f4; color: var(--text-2); flex: 0 0 auto; }
.cat-block.tone-good .cat-ic { background: var(--green-bg); color: var(--green); }
.cat-block.tone-warn .cat-ic { background: var(--amber-bg); color: var(--amber); }
.cat-block.tone-risk .cat-ic { background: var(--rose-bg); color: var(--rose); }
.cat-ic .icon { width: 18px; height: 18px; }
.cat-title { font-size: 15px; font-weight: 700; }
.cat-score { margin-left: auto; font-size: 18px; font-weight: 800; color: var(--text); }
.cat-score small { font-size: 12px; font-weight: 600; color: var(--text-3); }
.cat-level { font-size: 11.5px; font-weight: 700; padding: 4px 11px; border-radius: 20px; }
.cat-level.tone-good { background: var(--green-bg); color: var(--green); }
.cat-level.tone-warn { background: var(--amber-bg); color: var(--amber); }
.cat-level.tone-risk { background: #fee2e2; color: #dc2626; }
.cat-summary { margin: 12px 0 0; font-size: 13.5px; color: var(--text-2); line-height: 1.55; }
.cat-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.cat-col { border-radius: 10px; padding: 12px 14px; }
.cat-clear { background: #f0fdf4; border: 1px solid #dcfce7; }
.cat-missing { background: #fffbeb; border: 1px solid #fef3c7; }
.cat-col h4 { display: flex; align-items: center; gap: 7px; font-size: 13px; margin: 0 0 8px; }
.cat-col h4 .icon { width: 15px; height: 15px; }
.cat-clear h4 { color: #15803d; }
.cat-clear h4 .icon { color: var(--green); }
.cat-missing h4 { color: #b45309; }
.cat-missing h4 .icon { color: var(--amber); }
.cat-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.cat-col li { position: relative; padding-left: 14px; font-size: 13px; color: var(--text); line-height: 1.5; }
.cat-col li::before { content: ""; position: absolute; left: 2px; top: 8px; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .45; }
.cat-field { display: block; font-size: 13.5px; margin: 12px 0 0; line-height: 1.55; }
.cat-risk { display: flex; align-items: flex-start; gap: 8px; background: #fef2f2; border: 1px solid #fee2e2; border-radius: 8px; padding: 11px 13px; color: #b91c1c; }
.cat-risk-ic { flex: 0 0 auto; }
.cat-risk-ic .icon { display: block; width: 16px; height: 16px; margin-top: 1px; color: #dc2626; }
.cat-risk-body { flex: 1 1 auto; min-width: 0; }
.cat-flabel { font-weight: 700; color: #dc2626; }
.cat-ask { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; color: #075985; background: #e0f2fe; border-radius: 8px; padding: 11px 13px; margin: 12px 0 0; line-height: 1.55; }
.cat-ask-ic { flex: 0 0 auto; }
.cat-ask-ic .icon { display: block; width: 16px; height: 16px; margin-top: 1px; color: #0284c7; }
.cat-ask-body { flex: 1 1 auto; min-width: 0; }
.cat-ask-label { font-weight: 700; color: #0284c7; }

/* Check 3D V2 — khảo sát gia đình + phân tích theo người sử dụng */
.survey-card { background: var(--surface); border: 1px solid var(--border-2); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); margin-bottom: 16px; }
.survey-head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.survey-ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--purple-bg); color: var(--purple); flex: 0 0 auto; }
.survey-ic .icon { width: 20px; height: 20px; }
.survey-head-text h3 { font-size: 15px; margin: 0 0 3px; }
.survey-head-text p { font-size: 13px; color: var(--text-2); margin: 0; line-height: 1.5; }
.survey-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.survey-field { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; color: var(--text-2); font-weight: 600; }
.survey-field select, .survey-field input { font-size: 13.5px; font-weight: 500; color: var(--text); padding: 9px 11px; border: 1px solid var(--border-2); border-radius: 10px; background: #fff; outline: none; }
.survey-field select:focus, .survey-field input:focus { border-color: var(--brand); }

/* Trắc nghiệm DISC trong survey Check 3D */
.disc-quiz { margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--border-2); }
.disc-quiz-bare { margin-top: 4px; padding-top: 0; border-top: none; }
.disc-quiz-head { display: flex; flex-direction: column; gap: 2px; margin-bottom: 12px; }
.disc-quiz-head strong { font-size: 14.5px; color: var(--text); }
.disc-quiz-head span { font-size: 12.5px; color: var(--text-2); }
.disc-q { margin-bottom: 12px; }
.disc-q-title { font-size: 13.5px; font-weight: 600; color: var(--text); margin: 0 0 8px; }
.disc-opts { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 8px; }
.disc-opt { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--text); font-weight: 500; padding: 9px 11px; border: 1px solid var(--border-2); border-radius: 10px; background: #fff; cursor: pointer; transition: border-color .15s, background .15s; }
.disc-opt:hover { border-color: var(--brand); }
.disc-opt input { margin: 2px 0 0; accent-color: var(--brand); flex: 0 0 auto; }
.disc-opt:has(input:checked) { border-color: var(--brand); background: var(--brand-soft, #eef6ff); }
/* Trắc nghiệm từng câu (wizard): câu chưa tới bị khoá; ô sau khoá tới khi làm xong. */
.disc-q-locked { display: none; }
.disc-q:not(.disc-q-locked) { animation: cn-disc-in .24s ease; }
@keyframes cn-disc-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.cn-quizgate-hide { display: none !important; }
.disc-progress { font-size: 12.5px; font-weight: 800; color: var(--brand); margin: 0 0 12px; letter-spacing: .2px; }
.disc-progress.is-done { color: #15803d; }

.d3-design { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 4px; }
/* 3D: hero ước tính chi phí (đưa lên đầu báo cáo) */
.d3-costhero { background: linear-gradient(135deg, #ecfdf5, var(--surface) 70%); border: 1px solid var(--green-bg); border-radius: 14px; padding: 18px 20px; margin-bottom: 16px; display: flex; flex-direction: column; gap: 6px; }
.d3-costhero-eyebrow { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 800; color: var(--green); text-transform: uppercase; letter-spacing: .03em; }
.d3-costhero-eyebrow .icon { width: 16px; height: 16px; }
.d3-costhero-val { font-size: 26px; font-weight: 800; color: var(--text); line-height: 1.15; }
.d3-costhero-note { font-size: 12.5px; color: var(--text-2); line-height: 1.55; }
@media (max-width: 560px) { .d3-costhero { padding: 15px; } .d3-costhero-val { font-size: 22px; } }
.d3-chip { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--text); background: #f6f7f9; border: 1px solid var(--border); border-radius: 20px; padding: 6px 13px; }
.d3-chip b { font-weight: 600; color: var(--text-3); }
.d3-mat { font-size: 12.5px; font-weight: 600; color: var(--purple); background: var(--purple-bg); border-radius: 20px; padding: 6px 12px; }

.aud-list { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.aud-item { border-top: 1px dashed var(--border-2); padding-top: 12px; }
.aud-item:first-child { border-top: 0; padding-top: 0; }
.aud-issue { font-size: 14px; font-weight: 600; color: var(--text); margin: 0 0 5px; line-height: 1.5; }
.aud-risk { font-size: 13.5px; color: #b91c1c; margin: 0 0 6px; line-height: 1.5; }
.aud-risk span { font-weight: 700; color: #dc2626; }
.aud-fix { display: flex; align-items: flex-start; gap: 7px; font-size: 13.5px; color: #15803d; margin: 0; line-height: 1.5; }
.aud-fix .icon { width: 16px; height: 16px; margin-top: 1px; color: var(--green); flex: 0 0 auto; }

.d3-secs { display: flex; flex-direction: column; gap: 14px; }
.d3-sec { border: 1px solid var(--border); border-left: 4px solid var(--border-2); border-radius: var(--radius-sm); padding: 14px 16px; }
.d3-sec.tone-good { border-left-color: var(--green); }
.d3-sec.tone-warn { border-left-color: var(--amber); }
.d3-sec.tone-risk { border-left-color: #dc2626; }
.d3-sec-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.d3-sec-title { font-size: 14.5px; font-weight: 700; }
.d3-sec-score { margin-left: auto; font-size: 15px; font-weight: 800; }
.d3-sec-score small { font-size: 11px; font-weight: 600; color: var(--text-3); }
.d3-sec.tone-good .d3-sec-score { color: var(--green); }
.d3-sec.tone-warn .d3-sec-score { color: var(--amber); }
.d3-sec.tone-risk .d3-sec-score { color: #dc2626; }
.d3-sec ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.d3-sec li { position: relative; padding-left: 15px; font-size: 13.5px; color: var(--text); line-height: 1.5; }
.d3-sec li::before { content: ""; position: absolute; left: 3px; top: 8px; width: 5px; height: 5px; border-radius: 50%; background: var(--text-3); }

.d3-cost-est { display: flex; align-items: flex-start; gap: 9px; font-size: 14px; color: var(--text); line-height: 1.55; margin: 0 0 14px; }
.d3-cost-ic { width: 30px; height: 30px; border-radius: 9px; background: var(--green-bg); color: var(--green); display: grid; place-items: center; flex: 0 0 auto; }
.d3-cost-ic .icon { width: 16px; height: 16px; }
.d3-cost-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.d3-cost-list li { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; font-size: 13.5px; padding: 10px 13px; background: #fafbfc; border: 1px solid var(--border); border-radius: 10px; }
.d3-cost-list li > span { font-weight: 600; color: var(--text); flex: 1 1 auto; line-height: 1.45; }
.d3-cost-list b { font-weight: 600; color: var(--orange); text-align: right; flex: 0 1 auto; max-width: 52%; line-height: 1.4; }
.d3-cost-note { display: flex; align-items: flex-start; gap: 8px; margin: 12px 0 0; font-size: 12.5px; color: var(--text-2); line-height: 1.5; font-style: italic; }
.d3-cost-note .icon { width: 15px; height: 15px; margin-top: 1px; color: var(--text-3); flex: 0 0 auto; }

.d3-time { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.d3-time-col { background: #fafbfc; border: 1px solid var(--border); border-radius: 10px; padding: 12px 13px; }
.d3-time-lb { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; color: var(--brand); margin-bottom: 6px; }
.d3-time-lb .icon { width: 14px; height: 14px; }
.d3-time-col p { font-size: 13px; color: var(--text-2); margin: 0; line-height: 1.5; }
.d3-weak-label { font-size: 13px; font-weight: 700; color: var(--text-2); margin: 14px 0 8px; }
.d3-weak { display: flex; flex-wrap: wrap; gap: 8px; }
.d3-weak span { font-size: 12.5px; font-weight: 600; color: #b45309; background: #fffbeb; border: 1px solid #fef3c7; border-radius: 20px; padding: 5px 12px; }

.d3-regret-card { border-left: 3px solid var(--amber); }
.d3-regrets { margin: 0; padding-left: 0; list-style: none; counter-reset: rg; display: flex; flex-direction: column; gap: 10px; }
.d3-regrets li { counter-increment: rg; position: relative; padding-left: 38px; font-size: 14px; color: var(--text); line-height: 1.55; min-height: 26px; display: flex; align-items: center; }
.d3-regrets li::before { content: counter(rg); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 8px; background: var(--amber-bg); color: var(--amber); font-weight: 800; font-size: 13px; display: grid; place-items: center; }

.d3-cc-list { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.d3-cc-list li { display: flex; gap: 12px; align-items: baseline; }
.d3-cc-lb { flex: 0 0 120px; font-size: 12.5px; font-weight: 700; padding: 4px 11px; border-radius: 8px; text-align: center; }
.d3-cc-list li.tone-good .d3-cc-lb { background: var(--green-bg); color: var(--green); }
.d3-cc-list li.tone-warn .d3-cc-lb { background: var(--amber-bg); color: var(--amber); }
.d3-cc-list li.tone-risk .d3-cc-lb { background: #fee2e2; color: #dc2626; }
.d3-cc-tx { flex: 1; font-size: 14px; color: var(--text); line-height: 1.55; font-weight: 600; }
.d3-verdict { padding: 13px 15px; background: var(--brand-bg); border-radius: 10px; }

/* Check 3D — kết quả gọn gàng trên mobile (ĐẶT SAU base để thắng cascade, không bị ô trống thừa) */
@media (max-width: 560px) {
	/* Độ bền theo thời gian: 1 cột (hết cảnh 3 cột chữ vỡ vụn từng từ) */
	.d3-time { grid-template-columns: 1fr; gap: 10px; }
	.d3-time-col { padding: 11px 13px; }
	.d3-time-lb { font-size: 13px; }
	.d3-time-col p { font-size: 13.5px; }
	/* Chi phí dễ đội giá: nhãn trên — số dưới, căn trái, gọn 1 khối */
	.d3-cost-list li { flex-direction: column; align-items: stretch; gap: 3px; padding: 10px 12px; }
	.d3-cost-list li > span { line-height: 1.4; }
	.d3-cost-list b { max-width: none; text-align: left; }
	/* Kết luận AI: nhãn nhỏ gọn trên — nội dung dưới (hết cảnh ô màu trống cao 120px) */
	.d3-cc-list li { flex-direction: column; gap: 5px; align-items: stretch; }
	.d3-cc-lb { flex: 0 0 auto; width: auto; align-self: flex-start; }
	.d3-cc-tx { font-size: 13.5px; line-height: 1.5; }
}

/* Kết luận */
.result-conclusion { border-left: 3px solid var(--blue); }
.result-conclusion p { font-size: 14px; line-height: 1.6; color: var(--text); margin: 0; font-weight: 700; }
.compare-table .cell-note { color: #dc2626; font-style: italic; font-weight: 500; }

/* CTA + nút phụ */
.cta-row { display: flex; flex-wrap: wrap; gap: 10px; }
.btn-ghost { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; background: var(--surface); border: 1px solid var(--border-2); color: var(--text-2); font-weight: 600; font-size: 14px; padding: 10px 18px; border-radius: 12px; }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn-ghost .icon { width: 16px; height: 16px; }
.btn-sm { padding: 7px 12px; font-size: 12.5px; border-radius: 10px; }
.btn-sm .icon { width: 14px; height: 14px; }

/* Check vật liệu: ô tìm kiếm + chi tiết */
.material-search { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--border-2); border-radius: 14px; padding: 8px 8px 8px 16px; box-shadow: var(--shadow); }
.material-search > .icon { width: 18px; height: 18px; color: var(--text-3); flex: 0 0 auto; }
.material-search input { flex: 1; border: 0; outline: none; font-size: 14px; height: 40px; background: transparent; }
.muted-line { font-size: 13px; color: var(--text-3); margin: 12px 2px 0; }
.inline-link { color: var(--brand); font-weight: 600; cursor: pointer; }
.material-detail-head p { margin: 10px 0 0; font-size: 14px; color: var(--text-2); }
.procon { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; margin-top: 16px; }
.procon-col h4 { display: flex; align-items: center; gap: 7px; font-size: 13.5px; margin-bottom: 8px; }
.procon-col h4 .icon { width: 16px; height: 16px; }
.procon-col:nth-child(1) h4 .icon, .procon-col:nth-child(3) h4 .icon { color: var(--green); }
.procon-col:nth-child(2) h4 .icon, .procon-col:nth-child(4) h4 .icon { color: var(--rose); }
.procon-col ul { display: flex; flex-direction: column; gap: 6px; }
.procon-col li { font-size: 13px; color: var(--text-2); padding-left: 14px; position: relative; }
.procon-col li::before { content: "•"; position: absolute; left: 0; color: var(--text-3); }
.material-warn { display: flex; align-items: flex-start; gap: 8px; margin: 18px 0 0; padding: 12px 14px; background: var(--rose-bg); color: #9f1239; border-radius: 10px; font-size: 13.5px; font-weight: 500; }
.material-warn .icon { width: 17px; height: 17px; flex: 0 0 auto; margin-top: 1px; }

/* ===== Check vật liệu — cards màu hoá (mobile-first) ===== */
.matx { display: flex; flex-direction: column; gap: 14px; }
.matx-top { background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; padding: 18px; box-shadow: 0 2px 10px rgba(16,24,40,.05); }
.matx-tag { display: inline-block; font-weight: 800; font-size: 15px; color: var(--teal); background: var(--teal-bg); padding: 5px 14px; border-radius: 999px; }
.matx-desc { margin: 12px 0 0; font-size: 14px; color: var(--text-2); line-height: 1.55; }
.matx-cards { display: grid; grid-template-columns: 1fr; gap: 12px; }
@media ( min-width: 640px ) { .matx-cards { grid-template-columns: 1fr 1fr; } }
.matx-card { background: #fff; border: 1px solid #e5e7eb; border-left-width: 4px; border-radius: 14px; padding: 14px 16px; box-shadow: 0 2px 8px rgba(16,24,40,.04); }
.matx-card.tone-good { border-left-color: #22c55e; }
.matx-card.tone-bad { border-left-color: #ef4444; }
.matx-card.tone-use { border-left-color: #14b8a6; }
.matx-card.tone-avoid { border-left-color: #f97316; }
.matx-card-h { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.matx-card-ic { font-size: 17px; line-height: 1; }
.matx-card-h h5 { margin: 0; font-size: 14.5px; font-weight: 700; flex: 1 1 auto; }
.matx-card-n { font-size: 12px; font-weight: 800; min-width: 22px; height: 22px; padding: 0 7px; display: inline-grid; place-items: center; border-radius: 999px; color: #fff; }
.matx-card.tone-good .matx-card-n { background: #22c55e; }
.matx-card.tone-bad .matx-card-n { background: #ef4444; }
.matx-card.tone-use .matx-card-n { background: #14b8a6; }
.matx-card.tone-avoid .matx-card-n { background: #f97316; }
.matx-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 7px; }
.matx-list li { position: relative; padding-left: 16px; font-size: 13px; color: var(--text-1); line-height: 1.5; }
.matx-list li::before { content: ""; position: absolute; left: 2px; top: 7px; width: 6px; height: 6px; border-radius: 50%; }
.matx-card.tone-good .matx-list li::before { background: #22c55e; }
.matx-card.tone-bad .matx-list li::before { background: #ef4444; }
.matx-card.tone-use .matx-list li::before { background: #14b8a6; }
.matx-card.tone-avoid .matx-list li::before { background: #f97316; }
.matx-warn { display: flex; gap: 10px; align-items: flex-start; padding: 13px 15px; background: #fef2f2; border: 1px solid #fecaca; border-radius: 14px; }
.matx-warn-ic { color: #dc2626; flex: 0 0 auto; margin-top: 1px; }
.matx-warn-ic .icon { width: 19px; height: 19px; }
.matx-warn b { display: block; font-size: 13px; color: #b91c1c; margin-bottom: 2px; }
.matx-warn p { margin: 0; font-size: 13.5px; color: #7f1d1d; line-height: 1.55; }

/* Thư viện vật liệu / phụ kiện */
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.lib-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.lib-card-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.lib-ic { width: 36px; height: 36px; border-radius: 10px; background: var(--amber-bg); color: var(--amber); display: grid; place-items: center; flex: 0 0 auto; }
.lib-ic .icon { width: 18px; height: 18px; }
.lib-card-head h3 { font-size: 15px; }
.lib-brand { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-2); font-weight: 600; margin: 0 0 8px; }
.lib-brand .icon { width: 14px; height: 14px; color: var(--amber); flex: 0 0 auto; }
.lib-desc { font-size: 13px; color: var(--text-2); margin: 0 0 12px; }
.lib-meta { display: flex; flex-direction: column; gap: 6px; }
.lib-use, .lib-avoid { display: flex; align-items: center; gap: 6px; font-size: 12.5px; }
.lib-use { color: var(--green); }
.lib-avoid { color: var(--rose); }
.lib-use .icon, .lib-avoid .icon { width: 14px; height: 14px; flex: 0 0 auto; }

/* Trang PRO */
.pro-lead { font-size: 15px; color: var(--text-2); margin: 0 0 22px; }
.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; max-width: 760px; }
.plan-card { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.plan-card-pro { border: 2px solid var(--brand); }
.plan-flag { position: absolute; top: -11px; left: 26px; background: var(--brand); color: #fff; font-size: 11.5px; font-weight: 700; padding: 4px 12px; border-radius: 20px; }
.plan-head { margin-bottom: 18px; }
.plan-head h3 { font-size: 18px; }
.plan-price { font-size: 30px; font-weight: 800; margin: 8px 0 0; }
.plan-price span { font-size: 14px; font-weight: 500; color: var(--text-3); }
.plan-list { display: flex; flex-direction: column; gap: 11px; margin-bottom: 22px; flex: 1; }
.plan-list li { display: flex; align-items: flex-start; gap: 9px; font-size: 14px; color: var(--text-2); }
.plan-list .icon { width: 17px; height: 17px; color: var(--green); flex: 0 0 auto; margin-top: 1px; }
.plan-btn { width: 100%; justify-content: center; }

/* Thư viện lỗi: filter + thẻ lỗi */
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.chip-on, .chip-on:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
.error-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.error-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.error-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.error-cat { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--brand); background: var(--brand-bg); padding: 3px 10px; border-radius: 20px; }
.error-card h3 { font-size: 15.5px; margin-bottom: 14px; }
.error-meta { display: flex; flex-direction: column; gap: 10px; margin: 0 0 14px; }
.error-meta div { display: flex; flex-direction: column; gap: 2px; }
.error-meta dt { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--text-3); }
.error-meta dd { font-size: 13px; color: var(--text-2); margin: 0; }
.error-q { display: flex; align-items: flex-start; gap: 7px; font-size: 13px; color: var(--text-2); background: #fafbfc; border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; margin: 0 0 14px; }
.error-q .icon { width: 15px; height: 15px; color: var(--brand); flex: 0 0 auto; margin-top: 1px; }
.error-actions { display: flex; gap: 8px; margin-top: auto; }

/* Khung kết quả động + loading */
.dropzone .btn-ghost { margin-top: 4px; }
.dropzone-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 4px; }
.dropzone-actions .btn-ghost { margin-top: 0; }
.dropzone-cam-btn { color: var(--brand); border-color: var(--brand); background: var(--brand-bg); }
.dropzone-cam-btn:hover { filter: brightness(.97); }
/* Thẻ "đang nâng cấp" (thay ô tải tệp khi công cụ bị khoá). */
.maint-card { text-align: center; border: 1px dashed var(--border-2); border-radius: var(--radius); background: var(--surface); padding: 40px 24px; box-shadow: var(--shadow); }
.maint-ic { font-size: 44px; line-height: 1; margin-bottom: 12px; }
.maint-title { font-size: 20px; font-weight: 800; color: var(--text); margin: 0 0 8px; }
.maint-msg { font-size: 14px; color: var(--text-2); max-width: 560px; margin: 0 auto; line-height: 1.6; }
.dropzone-analyze { margin-top: 14px; }
.cn-source { font-size: 12.5px; color: var(--text-3); margin: 14px 2px; display: flex; align-items: center; gap: 6px; }
.cn-result { display: flex; flex-direction: column; gap: 22px; transition: opacity .2s; }
.cn-result.is-loading { opacity: .45; pointer-events: none; }
button[disabled] { opacity: .6; cursor: progress; }

/* Danh bạ "Đơn vị đạt chuẩn" cuối báo cáo (phương án A) */
.units-cta { border: 1px solid #c7d2fe; background: linear-gradient(135deg, #eef2ff, #f5f3ff); border-radius: var(--radius); padding: 22px; }
.units-cta-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; }
.units-cta-ic { width: 46px; height: 46px; border-radius: 12px; background: var(--brand); color: #fff; display: grid; place-items: center; flex: 0 0 auto; }
.units-cta-ic .icon { width: 24px; height: 24px; }
.units-cta-head h3 { font-size: 17px; margin: 0; }
.units-cta-head p { font-size: 13px; color: var(--text-2); margin: 6px 0 0; line-height: 1.55; }
.unit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.unit-card { position: relative; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 18px; display: flex; flex-direction: column; }
.unit-card.is-featured { border-color: var(--brand); box-shadow: 0 4px 14px rgba(99,102,241,.12); }
.unit-flag { position: absolute; top: -10px; left: 16px; background: var(--brand); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 11px; border-radius: 20px; }
.unit-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 12px; }
.unit-logo { width: 44px; height: 44px; border-radius: 12px; background: var(--brand-bg); color: var(--brand); font-weight: 800; font-size: 18px; display: grid; place-items: center; flex: 0 0 auto; }
.unit-id { min-width: 0; }
.unit-id h4 { font-size: 15.5px; margin: 0; }
.unit-badge { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; color: var(--green); background: var(--green-bg); padding: 2px 9px; border-radius: 20px; margin-top: 5px; }
.unit-badge .icon { width: 12px; height: 12px; }
.unit-meta { font-size: 12.5px; color: var(--text-3); margin: 7px 0 0; }
.unit-commit { display: flex; flex-direction: column; gap: 7px; margin: 0 0 14px; }
.unit-commit li { display: flex; gap: 7px; align-items: flex-start; font-size: 12.5px; color: var(--text-2); }
.unit-commit .icon { width: 14px; height: 14px; color: var(--green); flex: 0 0 auto; margin-top: 2px; }
.unit-cta-btn { width: 100%; justify-content: center; margin-top: auto; }
.unit-lead { margin-top: 12px; }

/* Empty-state: chưa có đơn vị thật → form kết nối gọn */
.unit-connect { background: #fff; border: 1px solid #c7d2fe; border-radius: 14px; padding: 18px; }
.unit-connect .unit-commit { margin-bottom: 12px; }
.unit-connect-note { margin: 0 0 14px; font-size: 13px; color: var(--text-2); line-height: 1.6; }

/* Form lead (trong thẻ đơn vị) */
.lead-form { display: flex; flex-direction: column; gap: 10px; }
.lead-form input { height: 44px; border: 1px solid var(--border-2); border-radius: 12px; padding: 0 14px; font-size: 14px; background: #fff; }
.lead-form input:focus { border-color: var(--brand); outline: none; }
.lead-form button { width: 100%; justify-content: center; }
.lead-result { margin: 10px 0 0; font-size: 13px; font-weight: 600; }
.lead-result:empty { display: none; }
.lead-result.is-ok { color: var(--green); }
.lead-result.is-err { color: var(--rose); }

@media (max-width: 600px) {
	.score-hero { flex-wrap: wrap; gap: 12px; }
	.material-search { flex-wrap: wrap; }
	.material-search input { width: 100%; }

	/* Khối kết nối đơn vị — gọn lại cho mobile, tránh lồng padding 2 lớp */
	.units-cta { padding: 16px 14px; border-radius: 16px; }
	.units-cta-head { gap: 11px; margin-bottom: 14px; }
	.units-cta-ic { width: 38px; height: 38px; border-radius: 10px; }
	.units-cta-ic .icon { width: 20px; height: 20px; }
	.units-cta-head h3 { font-size: 16px; line-height: 1.35; }
	.units-cta-head p { font-size: 12.5px; line-height: 1.6; margin-top: 5px; }
	.unit-connect { padding: 14px; border-radius: 12px; }
	.unit-connect .unit-commit { margin-bottom: 12px; }
	.unit-commit li { font-size: 13px; line-height: 1.4; }
	.unit-connect-note { font-size: 12.5px; line-height: 1.6; margin-bottom: 13px; }
	.unit-grid { grid-template-columns: 1fr; gap: 12px; }
	.unit-card { padding: 15px; }
	.lead-form input { height: 46px; font-size: 15px; }

	/* Phân tích chi tiết theo hạng mục — xếp dọc, hết bóp 2 cột */
	.cat-list { gap: 12px; }
	.cat-block { padding: 14px; }
	.cat-head { gap: 8px; }
	.cat-ic { width: 30px; height: 30px; border-radius: 9px; }
	.cat-ic .icon { width: 16px; height: 16px; }
	.cat-title { font-size: 14.5px; }
	.cat-score { font-size: 16px; }
	.cat-level { font-size: 11px; padding: 3px 9px; }
	.cat-summary { font-size: 13px; line-height: 1.6; margin-top: 10px; }
	.cat-cols { grid-template-columns: 1fr; gap: 10px; margin-top: 12px; }
	.cat-col { padding: 11px 13px; }
	.cat-col li { font-size: 12.5px; }
	.cat-risk, .cat-ask { font-size: 12.5px; line-height: 1.55; padding: 10px 12px; }
	.cat-field { margin-top: 10px; }
}

/* ===== Phân tích báo giá: animation đang phân tích ===== */
.analyze-anim { padding: 10px 6px; }
.analyze-anim-head { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 16px; line-height: 1.4; margin-bottom: 18px; }
.analyze-anim-head > span:last-child { background: linear-gradient(135deg, var(--brand, #16a34a), #0ea5e9); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.cn-spinner { width: 20px; height: 20px; border: 2.5px solid var(--brand-bg); border-top-color: var(--brand); border-radius: 50%; animation: cn-spin .8s linear infinite; flex: 0 0 auto; }
.analyze-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }
.analyze-steps li { display: flex; align-items: center; gap: 12px; font-size: 14px; color: var(--text-3); opacity: .5; transition: opacity .3s, color .3s; }
.analyze-steps li .astep-dot { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--border-2); flex: 0 0 auto; position: relative; transition: border-color .3s, background .3s; }
.analyze-steps li.is-active { opacity: 1; color: var(--text); }
.analyze-steps li.is-active .astep-dot { border-color: var(--brand); border-top-color: transparent; animation: cn-spin .8s linear infinite; }
.analyze-steps li.is-done { opacity: 1; color: var(--text); }
.analyze-steps li.is-done .astep-dot { border-color: var(--green); background: var(--green); animation: none; }
.analyze-steps li.is-done .astep-dot::after { content: ""; position: absolute; left: 5px; top: 2px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.cn-anim-err { color: var(--rose); font-size: 14px; margin: 0; }

/* ===== Hoạt cảnh thanh % (dùng chung mọi công cụ check) ===== */
.cn-prog { padding: 18px 6px 10px; }
.cn-prog-head { text-align: center; font-size: 15.5px; font-weight: 800; line-height: 1.45; margin-bottom: 16px; background: linear-gradient(135deg, var(--brand, #16a34a), #0ea5e9); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.cn-prog-pct { text-align: center; font-size: 30px; font-weight: 900; color: #16a34a; letter-spacing: .5px; margin-bottom: 12px; font-variant-numeric: tabular-nums; line-height: 1; }
.cn-prog-track { height: 26px; border-radius: 999px; background: #eef2f7; border: 2px solid #38bdf8; padding: 3px; box-shadow: inset 0 1px 3px rgba(2,6,23,.1), 0 0 0 3px rgba(56,189,248,.12); overflow: hidden; }
.cn-prog-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, #4ade80, #22c55e 70%, #16a34a); box-shadow: 0 0 12px rgba(34,197,94,.55); transition: width .2s linear; min-width: 16px; }
.cn-prog-step { margin-top: 13px; text-align: center; font-size: 13px; color: var(--text-2, #5b6b7a); min-height: 18px; font-weight: 500; }
@media (max-width: 560px) {
	.cn-prog-head { font-size: 14px; }
	.cn-prog-pct { font-size: 26px; }
	.cn-prog-track { height: 22px; }
}

/* ===== Kết quả sơ bộ (teaser) ===== */
.report-teaser { border: 1px solid #bbf7d0; background: linear-gradient(135deg, #f0fdf4, #ecfdf5); border-radius: var(--radius); padding: 20px; margin-bottom: 18px; }
.teaser-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 16px; }
.teaser-ic { color: var(--green); flex: 0 0 auto; }
.teaser-ic .icon { width: 30px; height: 30px; }
.teaser-head h2 { margin: 0; font-size: 18px; }
.teaser-head p { margin: 3px 0 0; font-size: 13.5px; color: var(--text-2); }
.teaser-grid { display: flex; gap: 22px; align-items: center; flex-wrap: wrap; }
.teaser-score { text-align: center; flex: 0 0 auto; }
.teaser-ring { width: 104px; height: 104px; border-radius: 50%; background: conic-gradient(var(--green) calc(var(--val) * 1%), #d1fae5 0); display: grid; place-items: center; margin: 0 auto; }
.teaser-ring-in { width: 80px; height: 80px; border-radius: 50%; background: #fff; display: grid; place-items: center; line-height: 1; }
.teaser-ring-num { font-size: 28px; font-weight: 800; color: var(--text); }
.teaser-ring-max { font-size: 12px; color: var(--text-3); }
.teaser-score > p { margin: 8px 0 0; font-size: 12.5px; color: var(--text-2); font-weight: 600; }
.teaser-chips { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; flex: 1 1 240px; }
.teaser-chips li { display: flex; gap: 9px; align-items: flex-start; font-size: 14px; }
.teaser-chips .icon { width: 18px; height: 18px; color: var(--green); flex: 0 0 auto; margin-top: 1px; }
.teaser-chips b { color: var(--text); }

/* ===== Cổng mở khoá báo cáo đầy đủ ===== */
.report-gatewrap { position: relative; }
.report-body.is-locked { max-height: 360px; overflow: hidden; filter: blur(5px); pointer-events: none; user-select: none; }
.report-gate { position: absolute; inset: 0; display: flex; align-items: flex-start; justify-content: center; padding: 16px; background: linear-gradient(to bottom, rgba(245,246,248,.15), var(--bg) 55%); }
.report-gate.is-done { opacity: 0; transition: opacity .25s; }
.report-gate-card { width: 100%; max-width: 460px; background: #fff; border: 1px solid var(--border-2); border-radius: var(--radius); box-shadow: var(--shadow-md); padding: 24px; text-align: center; margin-top: 26px; }
.report-gate-ic { width: 52px; height: 52px; border-radius: 14px; background: var(--brand-bg); color: var(--brand); display: grid; place-items: center; margin: 0 auto 12px; }
.report-gate-ic .icon { width: 26px; height: 26px; }
.report-gate-card h3 { margin: 0 0 4px; font-size: 19px; }
.report-gate-card > p { margin: 0 0 12px; font-size: 14px; color: var(--text-2); }
.report-gate-list { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 8px; text-align: left; }
.report-gate-list li { display: flex; gap: 9px; align-items: flex-start; font-size: 13.5px; }
.report-gate-list .icon { width: 17px; height: 17px; color: var(--green); flex: 0 0 auto; margin-top: 1px; }
.report-gate-form { margin: 0 0 8px; }
.btn-block { width: 100%; justify-content: center; }
.report-gate-trust { display: flex; gap: 8px; align-items: flex-start; justify-content: center; font-size: 12px; color: var(--text-3); margin: 10px 0 0; text-align: left; }
.report-gate-trust .icon { width: 15px; height: 15px; flex: 0 0 auto; margin-top: 1px; color: var(--green); }
@media (max-width: 560px) { .teaser-grid { justify-content: center; } .report-gate-card { padding: 18px; } }

/* ===== Báo giá 60/40: intro + CTA giữa báo cáo + phần khoá (blur) ===== */
.report-intro { display: flex; gap: 12px; align-items: flex-start; border: 1px solid #bbf7d0; background: linear-gradient(135deg, #f0fdf4, #ecfdf5); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 18px; }
.report-intro-ic { color: var(--green); flex: 0 0 auto; }
.report-intro-ic .icon { width: 28px; height: 28px; }
.report-intro h2 { margin: 0; font-size: 17px; }
.report-intro p { margin: 4px 0 0; font-size: 13.5px; color: var(--text-2); }
.report-cta { margin: 4px 0; display: flex; justify-content: center; }
.report-cta .report-gate-card { margin-top: 0; }
.report-locked { transition: filter .35s; }
.report-locked { transition: filter .35s; }
.report-locked.is-locked { position: relative; max-height: 440px; overflow: hidden; filter: blur(9px); pointer-events: none; user-select: none; opacity: .6; }
.report-lock-cover { position: absolute; inset: 0; z-index: 3; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 5px; padding: 24px; background: linear-gradient(to bottom, rgba(248,249,251,.9), rgba(248,249,251,.98)); }
.report-lock-cover-ic { width: 62px; height: 62px; border-radius: 50%; background: #fff; color: var(--brand); display: grid; place-items: center; box-shadow: var(--shadow-md); margin-bottom: 6px; }
.report-lock-cover-ic .icon { width: 28px; height: 28px; }
.report-lock-cover-t { margin: 0; font-size: 17px; font-weight: 800; color: var(--text); }
.report-lock-cover-s { margin: 0; font-size: 13px; color: var(--text-2); }
.report-locked.is-locked::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(245,246,248,0), var(--bg)); }
.report-unlocked { display: flex; gap: 10px; align-items: center; background: var(--green-bg); color: #166534; border: 1px solid #bbf7d0; border-radius: 12px; padding: 12px 16px; font-size: 14px; font-weight: 600; }
.report-unlocked-ic { width: 24px; height: 24px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; flex: 0 0 auto; font-size: 14px; }

/* Hé lộ "mức chênh" (làm mờ) + mở khoá qua Zalo */
.gate-peek { margin: 4px 0 16px; padding: 14px 16px; border-radius: 14px; background: linear-gradient(135deg, #fff7ed, #fef2f2); border: 1px dashed #fdba74; text-align: left; }
.gate-peek-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 5px 0; }
.gate-peek-label { font-size: 13.5px; color: var(--text-2); }
.gate-peek-num { font-size: 17px; font-weight: 800; color: #b91c1c; }
.cn-locknum { filter: blur(6px); user-select: none; letter-spacing: 1px; }
.gate-peek-hint { display: block; margin-top: 8px; font-size: 12px; color: var(--text-3); }
.gate-zalo-btn { display: flex; align-items: center; justify-content: center; gap: 9px; width: 100%; padding: 14px 18px; border-radius: 12px; background: #0068ff; color: #fff; font-size: 15.5px; font-weight: 800; text-decoration: none; box-shadow: 0 8px 20px rgba(0,104,255,.32); transition: transform .12s, box-shadow .12s; }
.gate-zalo-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(0,104,255,.42); }
.gate-zalo-ic { display: inline-grid; place-items: center; }
.gate-zalo-ic .icon { width: 19px; height: 19px; }
.gate-zalo-note { margin: 9px 0 0; font-size: 12.5px; color: var(--text-2); }
.gate-altlink { display: inline-block; margin: 14px 0 0; padding: 0; background: none; border: none; cursor: pointer; font-size: 13px; font-weight: 600; color: var(--brand); text-decoration: underline; }
.report-gate-form[hidden] { display: none; }
.report-gate-form { margin-top: 12px; }

/* Làm mờ số tiền/% trong bảng đối chiếu + mở khoá qua Zalo */
.cmp-lock-val { transition: filter .25s; }
.cmp-gated .cmp-lock-val { filter: blur(7px); -webkit-user-select: none; user-select: none; pointer-events: none; }
.cmp-zalo-gate { display: none; }
.cmp-gated .cmp-zalo-gate { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin: 6px 0 18px; padding: 16px 18px; border-radius: 16px; background: linear-gradient(135deg, #eff6ff, #faf5ff); border: 1px solid #bfdbfe; }
.cmp-zalo-gate-txt { display: flex; gap: 11px; align-items: flex-start; flex: 1 1 280px; }
.cmp-zalo-gate-ic { font-size: 22px; line-height: 1.2; }
.cmp-zalo-gate-txt b { font-size: 15px; color: var(--text-1, #0f172a); }
.cmp-zalo-gate-txt p { margin: 3px 0 0; font-size: 13px; line-height: 1.5; color: var(--text-2); }
.cmp-zalo-gate .gate-zalo-btn { width: auto; flex: 0 0 auto; }
@media (max-width: 560px) { .cmp-zalo-gate .gate-zalo-btn { width: 100%; } }
/* Nút mở khoá Zalo ngay trong từng thẻ (thay "Xem chi tiết" khi đang khoá) */
.cmp-card-zalo { display: none; }
.cmp-gated .cmp-card-zalo { display: flex; width: 100%; margin-top: 10px; font-size: 13.5px; padding: 12px 16px; }
.cmp-gated .cmp-more { display: none; }

/* Hiện ĐỐI CHIẾU GIÁ trước: ẩn các phần sau cho tới khi bảng đối chiếu tải xong */
.cn-result.cn-market-first > *:not(.market-cta) { display: none; }

/* Ô nhập SĐT mở khoá mức chênh (1 trường, dễ chịu) */
.cmp-unlock { flex: 1 1 320px; }
.cmp-unlock-form { display: flex; gap: 8px; }
.cmp-unlock-form input { flex: 1 1 auto; min-width: 0; padding: 12px 14px; border: 1.5px solid var(--border-2, #cbd5e1); border-radius: 10px; font-size: 14.5px; background: #fff; }
.cmp-unlock-form input:focus { border-color: var(--brand, #16a34a); outline: none; box-shadow: 0 0 0 3px rgba(22,163,74,.14); }
.cmp-unlock-form .btn-primary { flex: 0 0 auto; white-space: nowrap; }
.cmp-unlock-note { margin: 8px 0 0; font-size: 12px; color: var(--text-2); }
/* Nút CTA mở khoá: cam ấm, nổi bật, tăng tỉ lệ click (hợp tông web) */
.cmp-unlock-go, .cmp-card-zalo { background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%); color: #fff; border: none; font-weight: 800; box-shadow: 0 8px 20px rgba(37,99,235,.34); }
.cmp-unlock-go:hover, .cmp-card-zalo:hover { background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%); box-shadow: 0 12px 26px rgba(37,99,235,.46); transform: translateY(-1px); }
.cmp-zalo-alt { display: inline-block; margin-top: 8px; font-size: 12.5px; font-weight: 600; color: #2563eb; text-decoration: none; }
.cmp-zalo-alt:hover { text-decoration: underline; }
.cn-analyze-error { border-left: 4px solid #f59e0b; }
.cn-analyze-error-sub { margin-top: 8px; font-size: 13.5px; color: var(--text-2, #64748b); }
/* Form "nhờ check giúp" trong thẻ hết lượt check/giờ */
.cn-rl-lead { margin-top: 12px; max-width: 440px; }
.cmp-zalo-gate.is-pulse { animation: cn-pulse 1.3s ease; }
@keyframes cn-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(22,163,74,0); } 30% { box-shadow: 0 0 0 4px rgba(22,163,74,.28); } }
@media (max-width: 560px) { .cmp-unlock-form { flex-direction: column; } .cmp-unlock-form .btn-primary { width: 100%; } }

/* ===== Thanh nhắc "Mức chênh giá đang ẩn" bám theo khi cuộn ===== */
.cmp-follow {
	position: fixed; left: 12px; right: 88px; bottom: 16px; z-index: 9000;
	max-width: 460px;
	display: flex; align-items: center; gap: 11px;
	padding: 10px 11px 10px 14px; border-radius: 14px;
	background: #0F2A43; color: #fff; border: 1px solid rgba(255,255,255,.08);
	box-shadow: 0 16px 38px -10px rgba(15,42,67,.6);
	cursor: pointer;
	transform: translateY(150%); opacity: 0; pointer-events: none;
	transition: transform .38s cubic-bezier(.2,.9,.3,1), opacity .25s ease;
}
.cmp-follow.is-show { transform: translateY(0); opacity: 1; pointer-events: auto; animation: cmp-follow-glow 2.1s ease-in-out infinite; }
@keyframes cmp-follow-glow {
	0%, 100% { box-shadow: 0 16px 38px -10px rgba(15,42,67,.6); }
	50% { box-shadow: 0 16px 44px -6px rgba(37,99,235,.6); }
}
.cmp-follow-ic { font-size: 20px; line-height: 1; flex: none; filter: drop-shadow(0 1px 2px rgba(0,0,0,.3)); }
.cmp-follow-txt { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; flex: 1 1 auto; }
.cmp-follow-txt b { font-size: 13.5px; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmp-follow-txt b .ts { display: none; }
.cmp-follow-txt span { font-size: 11.5px; color: #bcd0de; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmp-follow-go { margin-left: auto; flex: none; background: #2563eb; color: #fff; font-weight: 800; font-size: 12.5px; padding: 8px 12px; border-radius: 9px; white-space: nowrap; }
.cmp-follow-go .gs { display: none; }
.cmp-follow-x { flex: none; width: 22px; height: 22px; padding: 0; border: 0; background: rgba(255,255,255,.12); color: #fff; border-radius: 50%; font-size: 15px; line-height: 1; cursor: pointer; }
.cmp-follow-x:hover { background: rgba(255,255,255,.22); }
@media (max-width: 480px) {
	.cmp-follow { left: 10px; right: 78px; padding: 9px 9px 9px 12px; gap: 8px; }
	.cmp-follow-ic { font-size: 18px; }
	.cmp-follow-txt b { font-size: 13px; }
	.cmp-follow-txt b .tf { display: none; }
	.cmp-follow-txt b .ts { display: inline; }
	.cmp-follow-txt span { display: none; }
	.cmp-follow-go { padding: 8px 11px; font-size: 12.5px; }
	.cmp-follow-go .gf { display: none; }
	.cmp-follow-go .gs { display: inline; }
}
@media (prefers-reduced-motion: reduce) { .cmp-follow.is-show { animation: none; } }

/* ===== Ổ khoá phủ 40% nội dung ===== */
.report-lockwrap { position: relative; }
.report-lock-badge { position: absolute; top: 14px; left: 50%; transform: translateX(-50%); z-index: 3; display: inline-flex; align-items: center; gap: 7px; background: rgba(17,24,39,.9); color: #fff; padding: 8px 16px; border-radius: 999px; font-size: 12.5px; font-weight: 600; box-shadow: var(--shadow-md); white-space: nowrap; max-width: calc(100% - 24px); }
.report-lock-badge .icon { width: 15px; height: 15px; flex: 0 0 auto; }
.report-lock-badge > span { overflow: hidden; text-overflow: ellipsis; }

/* Tinh chỉnh thẻ chi tiết cho gọn gàng */
.cat-block { padding: 18px 20px; }
.cat-summary { margin-top: 10px; color: var(--text-2); }
.cat-cols { align-items: stretch; }
.cat-col h4 { margin-bottom: 9px; letter-spacing: .1px; }
.cat-field { margin-top: 12px; }

/* Gợi ý "So sánh với thị trường" (cuối Check báo giá) */
.market-cta { border: 1px solid #a7e0d8; background: linear-gradient(135deg, #e9f7f5, #f0fbfa); border-radius: var(--radius); padding: 20px; }
.market-cta-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.market-cta-ic { width: 46px; height: 46px; border-radius: 12px; background: linear-gradient(135deg, #0f766e, #14b8a6); color: #fff; display: grid; place-items: center; flex: 0 0 auto; }
.market-cta-ic .icon { width: 24px; height: 24px; }
.market-cta-head h3 { margin: 0; font-size: 16px; line-height: 1.35; }
.market-cta-head p { margin: 5px 0 0; font-size: 13.5px; color: var(--text-2); line-height: 1.55; }
.market-cta-btn { width: 100%; justify-content: center; }
.market-cta-form { margin-top: 14px; }
.market-cta .lead-result:empty { display: none; }

/* Kết quả đối chứng "So sánh với thị trường" */
.market-msg { margin: 12px 0 0; font-size: 13.5px; color: #b45309; }
.market-loading { display: flex; gap: 10px; align-items: center; padding: 18px; font-size: 14px; color: var(--text-2); }
.market-result { margin-top: 14px; }
.market-box { background: #fff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 16px; }
.market-box-head { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 12px; }
.market-box-ic { width: 38px; height: 38px; border-radius: 10px; background: #ecfdf5; color: #047857; display: grid; place-items: center; flex: 0 0 auto; }
.market-box-ic .icon { width: 20px; height: 20px; }
.market-box-head h4 { margin: 0; font-size: 15px; }
.market-box-head p { margin: 4px 0 0; font-size: 12.5px; color: var(--text-2); line-height: 1.5; }
.market-summary { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.market-pill { font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }
.market-pill.tone-good { background: #dcfce7; color: #166534; }
.market-pill.tone-warn { background: #fef3c7; color: #92400e; }
.market-pill.tone-risk { background: #fee2e2; color: #991b1b; }
.market-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.market-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 560px; table-layout: fixed; }
.market-table col.c-item { width: 24%; }
.market-table col.c-price { width: 17%; }
.market-table col.c-range { width: 26%; }
.market-table col.c-diff { width: 17%; }
.market-table col.c-verdict { width: 16%; }
.market-table th, .market-table td { padding: 10px 10px; text-align: left; border-bottom: 1px solid #eef2f7; vertical-align: top; word-break: break-word; }
.market-table thead th { font-size: 11.5px; text-transform: uppercase; letter-spacing: .02em; color: var(--text-2); background: #f8fafc; vertical-align: bottom; line-height: 1.35; }
.market-table .ta-r { text-align: right; }
.market-table tbody td { vertical-align: middle; }
.market-table tbody td:first-child { vertical-align: top; }
.market-table tr.tone-risk td:first-child { box-shadow: inset 3px 0 0 #ef4444; }
.market-table tr.tone-warn td:first-child { box-shadow: inset 3px 0 0 #f59e0b; }
.market-table tr.tone-good td:first-child { box-shadow: inset 3px 0 0 #22c55e; }
.market-sub { display: block; font-size: 11.5px; color: var(--text-2); margin-top: 2px; }
.market-approx { display: block; font-size: 11px; color: #94a3b8; margin-top: 2px; }
.market-unit { font-size: 11px; color: var(--text-2); }
.market-range { color: var(--text-2); }
.market-verdict { display: inline-block; font-size: 11.5px; font-weight: 600; padding: 4px 8px; border-radius: 8px; white-space: normal; line-height: 1.25; }
.market-verdict.tone-good { background: #dcfce7; color: #166534; }
.market-verdict.tone-warn { background: #fef3c7; color: #92400e; }
.market-verdict.tone-risk { background: #fee2e2; color: #991b1b; }
.market-unmatched { margin-top: 12px; padding: 12px 14px; background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px; font-size: 12.5px; color: #92400e; line-height: 1.55; }
.market-unmatched strong { color: #b45309; }
.market-unmatched-note { margin: 8px 0 0; font-size: 12px; color: #a16207; line-height: 1.55; }
.market-disc { display: flex; gap: 8px; align-items: flex-start; margin: 14px 0 0; font-size: 12px; color: var(--text-2); line-height: 1.5; }
.market-disc .icon { width: 16px; height: 16px; flex: 0 0 auto; margin-top: 1px; }
.market-note { padding: 14px; font-size: 13.5px; color: var(--text-2); }
.market-download { margin-top: 16px; padding-top: 16px; border-top: 1px dashed #c7d2fe; }
.market-dl-btn { width: 100%; justify-content: center; }
.market-dl-note { margin: 8px 0 0; font-size: 12px; color: var(--text-2); text-align: center; line-height: 1.5; }
.market-warn { display: flex; gap: 8px; align-items: flex-start; margin: 0 0 12px; padding: 10px 12px; background: #fffbeb; border: 1px solid #fde68a; border-radius: 10px; font-size: 12.5px; color: #92400e; line-height: 1.5; }
.market-warn .icon { width: 16px; height: 16px; flex: 0 0 auto; margin-top: 1px; }
.market-assumed { display: flex; gap: 5px; align-items: center; font-size: 11px; color: #b45309; margin-top: 3px; }
.market-assumed .icon { width: 13px; height: 13px; flex: 0 0 auto; }
.market-grades { display: block; font-size: 11px; color: #4f46e5; margin-top: 2px; }
.market-total { display: flex; gap: 12px; align-items: flex-start; margin: 16px 0 0; padding: 14px 16px; border-radius: 12px; border: 1px solid; }
.market-total.tone-risk { background: #fef2f2; border-color: #fecaca; }
.market-total.tone-warn { background: #fffbeb; border-color: #fde68a; }
.market-total.tone-good { background: #f0fdf4; border-color: #bbf7d0; }
.market-total-ic { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; flex: 0 0 auto; color: #fff; }
.market-total.tone-risk .market-total-ic { background: #ef4444; }
.market-total.tone-warn .market-total-ic { background: #f59e0b; }
.market-total.tone-good .market-total-ic { background: #22c55e; }
.market-total-ic .icon { width: 20px; height: 20px; }
.market-total-title { margin: 0; font-size: 14.5px; font-weight: 600; line-height: 1.45; color: var(--text-1); }
.market-total-title strong { font-size: 16px; }
.market-total.tone-risk .market-total-title strong { color: #b91c1c; }
.market-total.tone-warn .market-total-title strong { color: #b45309; }
.market-total-sub { margin: 4px 0 0; font-size: 12.5px; color: var(--text-2); line-height: 1.5; }

/* Đối chứng dạng CARD (mobile-first, mỗi hạng mục như 1 sản phẩm) */
.market-cards { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 4px; }
@media ( min-width: 760px ) { .market-cards { grid-template-columns: 1fr 1fr; } }
.market-card { background: #fff; border: 1px solid #e5e7eb; border-left-width: 4px; border-radius: 16px; padding: 16px; box-shadow: 0 2px 8px rgba(16,24,40,.06); }
.market-card.lvl-high { border-left-color: #ef4444; }
.market-card.lvl-good, .market-card.lvl-fair { border-left-color: #22c55e; }
.market-card.lvl-low  { border-left-color: #f97316; }
.market-card-title { margin: 0 0 12px; font-size: 20px; font-weight: 700; line-height: 1.3; color: var(--text-1); }
.market-card-emo { font-size: 14px; }
.market-card-specs { margin: 0 0 12px; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 5px; }
.market-card-specs li { position: relative; padding-left: 16px; font-size: 12.5px; color: var(--text-2); line-height: 1.45; }
.market-card-specs li::before { content: "•"; position: absolute; left: 2px; color: #94a3b8; }
.market-card-specs li.is-note { color: #94a3b8; font-style: italic; }
.market-card-line { display: flex; flex-direction: column; gap: 2px; margin-bottom: 12px; }
.market-card-label { font-size: 12.5px; color: var(--text-2); }
.market-card-you { font-size: 24px; font-weight: 700; color: #16a34a; line-height: 1.2; }
.market-card-you small { font-size: 13px; font-weight: 500; color: var(--text-2); }
.market-card-mkt { font-size: 16px; font-weight: 600; color: var(--text-1); line-height: 1.2; }
.market-card-gap-amt { font-size: 22px; font-weight: 800; line-height: 1.2; }
.market-card-gap-amt small { font-size: 13px; font-weight: 600; color: #94a3b8; }
.market-card.lvl-high .market-card-gap-amt { color: #dc2626; }
.market-card.lvl-low  .market-card-gap-amt { color: #c2410c; }
.market-card.lvl-good .market-card-gap-amt, .market-card.lvl-fair .market-card-gap-amt { color: #16a34a; }
.market-card-badge { align-self: flex-start; display: inline-block; font-size: 13px; font-weight: 700; padding: 5px 12px; border-radius: 999px; }
.market-card.lvl-high .market-card-badge { background: #fef2f2; color: #b91c1c; }
.market-card.lvl-good .market-card-badge, .market-card.lvl-fair .market-card-badge { background: #f0fdf4; color: #15803d; }
.market-card.lvl-low  .market-card-badge { background: #fff7ed; color: #c2410c; }
.market-card-more { margin-top: 16px; }
.market-card-more > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; font-size: 14px; font-weight: 600; color: var(--brand); padding: 9px 16px; border: 1px solid var(--border-2); border-radius: 10px; }
.market-card-more > summary::-webkit-details-marker { display: none; }
.market-card-more[open] > summary { color: var(--text-2); }
.market-card-detail { margin-top: 10px; font-size: 13px; color: var(--text-2); line-height: 1.55; }

/* Card TỔNG KẾT cuối báo cáo */
.market-recap { margin-top: 20px; background: #fff; border: 1px solid #e5e7eb; border-top-width: 5px; border-radius: 16px; padding: 18px; box-shadow: 0 2px 10px rgba(16,24,40,.07); }
.market-recap.lvl-good { border-top-color: #22c55e; }
.market-recap.lvl-low  { border-top-color: #f97316; }
.market-recap.lvl-high { border-top-color: #ef4444; }
.market-recap-head { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.market-recap-ic { font-size: 22px; line-height: 1; }
.market-recap-head h4 { margin: 0; font-size: 18px; font-weight: 700; }
.market-recap-badge { display: inline-block; margin-top: 4px; font-size: 13px; font-weight: 700; padding: 4px 12px; border-radius: 999px; }
.market-recap.lvl-good .market-recap-badge { background: #f0fdf4; color: #15803d; }
.market-recap.lvl-low  .market-recap-badge { background: #fff7ed; color: #c2410c; }
.market-recap.lvl-high .market-recap-badge { background: #fef2f2; color: #b91c1c; }
.market-recap-counts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 14px; }
.market-recap-counts .rc { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 4px; background: #f8fafc; border-radius: 12px; }
.market-recap-counts .rc b { font-size: 22px; font-weight: 800; line-height: 1; color: var(--text-1); }
.market-recap-counts .rc span { font-size: 11px; color: var(--text-2); text-align: center; }
.market-recap-counts .c-high b { color: #dc2626; }
.market-recap-counts .c-ok b { color: #16a34a; }
.market-recap-counts .c-low b { color: #c2410c; }
.market-recap-money { border: 1px solid #eef2f7; border-radius: 12px; overflow: hidden; }
.market-recap-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 14px; font-size: 14px; }
.market-recap-row span { color: var(--text-2); }
.market-recap-row b { font-weight: 700; color: var(--text-1); }
.market-recap-row + .market-recap-row { border-top: 1px solid #eef2f7; }
.market-recap-row.is-gap { background: #f8fafc; }
.market-recap-row.is-gap b { font-size: 18px; }
.market-recap.lvl-high .market-recap-row.is-gap b { color: #dc2626; }
.market-recap.lvl-low .market-recap-row.is-gap b { color: #c2410c; }
.market-recap.lvl-good .market-recap-row.is-gap b { color: #16a34a; }
.market-recap-row.is-gap b small { font-size: 13px; font-weight: 600; color: #94a3b8; }
.market-recap-note { margin: 8px 2px 0; font-size: 11.5px; color: #94a3b8; }
.market-recap-concl { margin: 14px 0 0; padding: 12px 14px; background: #f8fafc; border-radius: 12px; font-size: 13.5px; line-height: 1.55; color: var(--text-1); }

/* ===== Kết quả đối chứng — UI cards + tổng kết (chuyên nghiệp) ===== */
.cmp { display: flex; flex-direction: column; gap: 18px; }
.cmp-top { background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; padding: 18px; box-shadow: 0 2px 10px rgba(16,24,40,.05); }
.cmp-top-head h3 { margin: 0; font-size: 19px; font-weight: 800; }
.cmp-top-head p { margin: 4px 0 14px; font-size: 13px; color: var(--text-2); }
.cmp-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media ( min-width: 720px ) { .cmp-stats { grid-template-columns: repeat(4, 1fr); } }
.cmp-stat { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; }
.cmp-stat b { font-size: 26px; font-weight: 800; line-height: 1; }
.cmp-stat span { font-size: 12px; line-height: 1.3; }
.cmp-stat.s-high { background: #fef2f2; } .cmp-stat.s-high b { color: #dc2626; } .cmp-stat.s-high span { color: #b91c1c; }
.cmp-stat.s-warn { background: #fff7ed; } .cmp-stat.s-warn b { color: #ea580c; } .cmp-stat.s-warn span { color: #c2410c; }
.cmp-stat.s-good { background: #f0fdf4; } .cmp-stat.s-good b { color: #16a34a; } .cmp-stat.s-good span { color: #15803d; }
.cmp-stat.s-level { background: #f8fafc; border: 1px solid #e5e7eb; }
.cmp-stat-ic { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; color: var(--text-2); }
.cmp-stat-ic .icon { width: 22px; height: 22px; }
.cmp-stat.s-level > div { display: flex; flex-direction: column; }
.cmp-stat.s-level > div span { font-size: 11.5px; color: var(--text-2); }
.cmp-stat.s-level > div b { font-size: 18px; }
.cmp-stat.s-level.lvl-high > div b { color: #dc2626; }
.cmp-stat.s-level.lvl-low > div b { color: #c2410c; }
.cmp-stat.s-level.lvl-good > div b { color: #16a34a; }
.cmp-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cmp-filter-lbl { font-size: 13px; font-weight: 600; color: var(--text-2); margin-right: 2px; }
.cmp-chip { font-size: 13px; font-weight: 600; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--border-2); background: #fff; color: var(--text-2); cursor: pointer; }
.cmp-chip.is-on { background: #eef2ff; border-color: #c7d2fe; color: var(--brand); }
.cmp-list-title { margin: 2px 0 -4px; font-size: 15px; font-weight: 700; }
.cmp-cards { display: grid; grid-template-columns: 1fr; gap: 16px; }
.cmp-card { display: grid; grid-template-columns: 1fr; background: #fff; border: 1px solid #e5e7eb; border-left-width: 5px; border-radius: 16px; overflow: hidden; box-shadow: 0 2px 8px rgba(16,24,40,.05); }
@media ( min-width: 720px ) { .cmp-card { grid-template-columns: 1.05fr 1fr; } }
.cmp-card.lvl-high { border-left-color: #ef4444; }
.cmp-card.lvl-good, .cmp-card.lvl-fair { border-left-color: #22c55e; }
.cmp-card.lvl-low { border-left-color: #f97316; }
.cmp-card.is-extra { display: none; }
.cmp-cards.is-open .cmp-card.is-extra, .cmp-cards.is-filtered .cmp-card.is-extra { display: grid; }
.cmp-card.is-hidden { display: none !important; }
.cmp-card-main { padding: 16px; }
@media ( min-width: 720px ) { .cmp-card-main { border-right: 1px solid #f1f5f9; } }
.cmp-card-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.cmp-card-ic { width: 38px; height: 38px; flex: 0 0 auto; display: grid; place-items: center; font-size: 20px; background: #f1f5f9; border-radius: 10px; }
.cmp-card-head h5 { margin: 0; font-size: 16px; font-weight: 700; flex: 1 1 auto; min-width: 110px; }
.cmp-badge { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.cmp-card.lvl-high .cmp-badge { background: #fef2f2; color: #b91c1c; }
.cmp-card.lvl-good .cmp-badge, .cmp-card.lvl-fair .cmp-badge { background: #f0fdf4; color: #15803d; }
.cmp-card.lvl-low .cmp-badge { background: #fff7ed; color: #c2410c; }
.cmp-mat-t { margin: 0 0 6px; font-size: 13px; font-weight: 600; }
.cmp-card-mat ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; }
.cmp-card-mat li { position: relative; padding-left: 15px; font-size: 12.5px; color: var(--text-2); line-height: 1.45; }
.cmp-card-mat li::before { content: "•"; position: absolute; left: 2px; color: #94a3b8; }
.cmp-card-mat li.is-note { color: #94a3b8; font-style: italic; }
.cmp-card-stats { padding: 14px 16px; background: #fafbfc; }
@media ( min-width: 720px ) { .cmp-card-stats { background: #fff; } }
.cmp-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px solid #f1f5f9; }
.cmp-row:last-of-type { border-bottom: 0; }
.cmp-row-k { font-size: 13px; color: var(--text-2); }
.cmp-row-v { font-size: 14px; font-weight: 700; color: var(--text-1); text-align: right; }
.cmp-row-v.v-you { color: #16a34a; }
.cmp-row-v.v-gap.lvl-high { color: #dc2626; }
.cmp-row-v.v-gap.lvl-low { color: #c2410c; }
.cmp-row-v.v-gap.lvl-good, .cmp-row-v.v-gap.lvl-fair { color: #16a34a; }
.cmp-verdict { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; }
.cmp-dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: 0 0 auto; }
/* CTA "Nhận báo giá chuẩn hạng mục" theo từng thẻ → form Họ tên + SĐT → Telegram */
.cmp-cta-wrap { margin-top: 12px; }
.cmp-gated .cmp-cta-wrap { display: none; } /* bật cổng SĐT → dùng nút gate cũ, ẩn CTA này */
.cmp-cta { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 12px 14px; border-radius: 11px; font-size: 13.5px; font-weight: 800; font-family: inherit; border: 0; cursor: pointer; line-height: 1.3; text-align: center; }
.cmp-cta-ok { background: #fff; color: #16a34a; border: 1.6px solid #bbf7d0; }
.cmp-cta-ok:hover { background: #f0fdf4; }
.cmp-cta-warn { background: linear-gradient(135deg, #f97316, #fb923c); color: #fff; box-shadow: 0 8px 18px rgba(249,115,22,.3); }
.cmp-cta-warn:hover { filter: brightness(.98); }
.cmp-cta-h { margin: 0 0 9px; font-size: 12.5px; font-weight: 700; color: #334155; line-height: 1.45; }
.cmp-cta-h-hot { color: #b91c1c; }
.cmp-cta-form { display: flex; flex-direction: column; gap: 9px; }
.cmp-cta-form[hidden] { display: none; }
.cmp-cta-form input { font-family: inherit; font-size: 13.5px; padding: 10px 12px; border: 1px solid #e5e7eb; border-radius: 9px; outline: none; background: #fff; }
.cmp-cta-form input:focus { border-color: var(--brand); }
.cmp-cta-go { border: 0; cursor: pointer; font-family: inherit; font-weight: 800; font-size: 13.5px; padding: 12px; border-radius: 10px; background: linear-gradient(135deg, #16a34a, #22c55e); color: #fff; box-shadow: 0 8px 18px rgba(22,163,74,.28); transition: filter .12s; }
.cmp-cta-go-hot { background: linear-gradient(135deg, #ef4444, #f97316); box-shadow: 0 8px 18px rgba(239,68,68,.3); }
.cmp-cta-go:hover { filter: brightness(.97); }
.cmp-cta-wrap .lead-result { margin: 9px 0 0; font-size: 12.5px; font-weight: 600; color: #16a34a; text-align: center; }
.cmp-cta-wrap .lead-result.is-err { color: #dc2626; }
.cmp-more { margin-top: 10px; }
.cmp-more > summary { list-style: none; cursor: pointer; text-align: center; display: block; font-size: 13px; font-weight: 600; color: var(--brand); padding: 9px; border: 1px solid var(--border-2); border-radius: 10px; }
.cmp-more > summary::-webkit-details-marker { display: none; }
.cmp-more-body { margin-top: 10px; font-size: 12.5px; color: var(--text-2); line-height: 1.55; }
.cmp-showmore { width: 100%; text-align: center; font-size: 14px; font-weight: 600; color: var(--brand); background: #fff; border: 1px solid var(--border-2); border-radius: 12px; padding: 12px; cursor: pointer; }
.cmp-showmore-ic { display: inline-block; transition: transform .2s; }
.cmp-showmore.is-open .cmp-showmore-ic { transform: rotate(180deg); }
.cmp-recap { background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; padding: 18px; box-shadow: 0 2px 10px rgba(16,24,40,.06); }
.cmp-recap-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.cmp-recap-ic { font-size: 20px; }
.cmp-recap-head h4 { margin: 0; font-size: 17px; font-weight: 800; }
.cmp-recap-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media ( min-width: 760px ) { .cmp-recap-grid { grid-template-columns: 1fr 1fr 1fr; align-items: start; } }
.cmp-rk { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid #f1f5f9; font-size: 13.5px; }
.cmp-rk:last-child { border-bottom: 0; }
.cmp-rk-dot { width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto; }
.cmp-rk-dot.d-blue { background: #3b82f6; } .cmp-rk-dot.d-red { background: #ef4444; } .cmp-rk-dot.d-amber { background: #f97316; } .cmp-rk-dot.d-green { background: #22c55e; }
.cmp-rk-t { flex: 1 1 auto; color: var(--text-2); }
.cmp-rk b { font-weight: 800; }
.cmp-recap-money { border: 1px solid #eef2f7; border-radius: 12px; overflow: hidden; align-self: start; }
.cmp-rm { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; padding: 10px 12px; font-size: 13.5px; }
.cmp-rm + .cmp-rm { border-top: 1px solid #eef2f7; }
.cmp-rm span { color: var(--text-2); }
.cmp-rm b { font-weight: 800; color: var(--text-1); text-align: right; }
.cmp-rm.is-gap { background: #fef2f2; }
.cmp-rm.is-gap b { color: #dc2626; }
.cmp-gauge-col { text-align: center; }
.cmp-gauge-t { margin: 0 0 4px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.cmp-gauge { display: block; width: 180px; max-width: 100%; height: auto; margin: 2px auto 0; }
.cmp-gauge-lvl { margin: 2px 0 0; font-size: 22px; font-weight: 800; }
.cmp-gauge-lvl.lvl-high { color: #dc2626; } .cmp-gauge-lvl.lvl-low { color: #c2410c; } .cmp-gauge-lvl.lvl-good { color: #16a34a; }
.cmp-gauge-sub { margin: 4px auto 0; max-width: 240px; font-size: 12px; color: var(--text-2); line-height: 1.5; }
.cmp-reco { display: flex; gap: 10px; align-items: flex-start; margin-top: 16px; padding: 12px 14px; background: #eff6ff; border: 1px solid #dbeafe; border-radius: 12px; }
.cmp-reco-ic { font-size: 18px; flex: 0 0 auto; }
.cmp-reco b { display: block; font-size: 13px; color: #1d4ed8; margin-bottom: 2px; }
.cmp-reco p { margin: 0; font-size: 13px; color: var(--text-1); line-height: 1.55; }
.cmp-disc { display: flex; gap: 8px; align-items: flex-start; margin: 14px 0 0; font-size: 11.5px; color: #94a3b8; line-height: 1.5; }
/* Ghi chú địa bàn (báo giá xây dựng) — hệ số giá theo khu vực công trình */
.cmp-region { margin: 14px 0 0; font-size: 12.5px; color: var(--text-2, #64748b); }
.cmp-region strong { color: var(--text-1, #0f172a); }

/* ===== Kết quả đối chiếu V2: 1 thẻ kết quả + phễu SĐT 2 lựa chọn ===== */
.v2-card { border-radius: 22px; overflow: hidden; background: linear-gradient(160deg, #0f2e1f, #123524 55%, #0b2418); color: #fff; box-shadow: 0 14px 44px rgba(2, 6, 23, .22); }
.v2-hd { display: flex; align-items: center; gap: 11px; padding: 20px 22px 12px; }
.v2-logo { width: 38px; height: 38px; border-radius: 10px; background: #16a34a; display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 21px; flex: 0 0 auto; }
.v2-brand b { font-size: 15px; letter-spacing: .3px; }
.v2-brand em { display: block; font-style: normal; font-size: 10.5px; color: #86efac; }
.v2-badge { margin-left: auto; background: rgba(22, 163, 74, .25); border: 1px solid #16a34a; color: #86efac; font-size: 10.5px; font-weight: 700; padding: 5px 10px; border-radius: 999px; white-space: nowrap; }
.v2-title { margin: 4px 22px 0; font-size: 20px; font-weight: 800; color: #fff; }
.v2-sub { margin: 4px 22px 14px; font-size: 12.5px; color: #a7f3d0; }
.v2-stats { display: flex; gap: 10px; padding: 0 22px 14px; }
.v2-stat { flex: 1; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .13); border-radius: 14px; padding: 11px 13px; min-width: 0; }
.v2-stat span { font-size: 10.5px; color: #94e2b8; display: block; margin-bottom: 3px; }
.v2-stat b { font-size: 16.5px; color: #fff; word-break: break-word; }
.v2-stat.s-hot b { color: #fca5a5; }
.v2-stat.s-save b { color: #6ee7b7; }
.v2-card .cmp-zalo-gate { margin: 0 22px 14px; }
.v2-items { margin: 0 22px; background: #fff; border-radius: 16px; color: #0f172a; overflow: hidden; }
.v2-items-h { display: flex; padding: 10px 16px; background: #f1f5f9; font-size: 10.5px; font-weight: 700; color: #64748b; letter-spacing: .4px; text-transform: uppercase; }
.v2-items-h .c1 { flex: 1; }
.v2-items-h .c2 { width: 106px; text-align: right; }
.v2-items-h .c3 { width: 128px; text-align: right; }
.v2-row { display: flex; align-items: center; flex-wrap: wrap; padding: 10px 16px; border-bottom: 1px dashed #e2e8f0; font-size: 13.5px; }
.v2-row:last-of-type { border-bottom: none; }
.v2-row.is-extra { display: none; }
.v2-row.lvl-high { background: #fff8f8; }
.v2-row .c1 { flex: 1; min-width: 0; font-weight: 600; padding-right: 10px; }
.v2-row .c1 small { display: block; font-weight: 400; color: #94a3b8; font-size: 11px; margin-top: 1px; }
.v2-row .c2 { width: 106px; text-align: right; color: #475569; font-size: 13px; }
.v2-row .c3 { width: 128px; text-align: right; }
.v2-pill { display: inline-block; font-weight: 800; font-size: 10.5px; padding: 4px 9px; border-radius: 999px; white-space: nowrap; }
.v2-pill.p-hi { background: #fee2e2; color: #dc2626; }
.v2-pill.p-ok { background: #dcfce7; color: #16a34a; }
.v2-pill.p-lo { background: #ffedd5; color: #c2410c; }
.v2-pill.p-est { background: #e0e7ff; color: #4338ca; }
.v2-exp { display: flex; width: 100%; margin-top: 8px; gap: 10px; align-items: center; background: #fef2f2; border-radius: 10px; padding: 8px 12px; font-size: 12px; color: #7f1d1d; flex-wrap: wrap; }
.v2-exp b { color: #dc2626; }
/* Hàng "thấp bất thường" — tông hổ phách (cảnh báo cắt giảm vật liệu), nút vàng-cam */
.v2-exp-low { background: #fff7ed; color: #7c2d12; }
.v2-exp-low b { color: #c2410c; }
.v2-exp-low .v2-cta { background: #ea580c; }
.v2-cta { margin-left: auto; background: #dc2626; color: #fff; font-weight: 700; font-size: 11.5px; padding: 7px 13px; border-radius: 8px; border: none; cursor: pointer; white-space: nowrap; }
.v2-cta:hover { background: #b91c1c; }
.v2-more { display: block; width: 100%; padding: 10px; background: #f8fafc; border: none; border-top: 1px dashed #e2e8f0; color: #64748b; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.v2-warnline { margin: 12px 22px 0; font-size: 12px; color: #fcd34d; line-height: 1.5; }
.v2-concl { margin: 14px 22px 0; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .13); border-radius: 13px; padding: 12px 15px; font-size: 13px; color: #d1fae5; line-height: 1.55; }
.v2-concl-b { color: #fff; font-weight: 700; }
.v2-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 22px 18px; font-size: 12px; color: #86efac; flex-wrap: wrap; }
.v2-foot b { color: #fff; }
.v2-unmatched { margin: 12px 0 0; font-size: 12px; color: var(--text-2, #64748b); line-height: 1.55; }
/* Phễu SĐT */
.v2-lead { margin-top: 16px; background: #fff; border: 1.5px solid #bbf7d0; border-radius: 20px; padding: 20px 22px; box-shadow: 0 8px 26px rgba(22, 163, 74, .10); }
.v2-lead.is-pulse { animation: cn-pulse 1.3s ease; }
.v2-lead h3 { margin: 0; font-size: 17px; color: var(--text-1, #0f172a); }
.v2-lead-sub { margin: 5px 0 13px; font-size: 13px; color: var(--text-2, #64748b); line-height: 1.5; }
.v2-lead-sub b { color: #16a34a; }
.v2-opts { display: flex; gap: 10px; margin-bottom: 12px; }
.v2-opt { flex: 1; border: 2px solid #e2e8f0; background: #fff; border-radius: 14px; padding: 11px 13px; font-size: 12.5px; color: #64748b; cursor: pointer; text-align: left; line-height: 1.45; }
.v2-opt b { display: block; font-size: 13.5px; margin-bottom: 2px; color: #334155; }
.v2-opt.is-on { border-color: #16a34a; background: #f0fdf4; color: #14532d; }
.v2-opt.is-on b { color: #0f172a; }
.v2-lead-form { display: flex; gap: 9px; }
.v2-lead-form input { flex: 1; height: 46px; border: 1px solid #cbd5e1; border-radius: 12px; padding: 0 14px; font-size: 14px; background: #fff; min-width: 0; }
.v2-lead-form input:focus { border-color: var(--brand, #16a34a); outline: none; }
.v2-go { height: 46px; padding: 0 18px; background: linear-gradient(135deg, #f97316, #dc2626); color: #fff; font-weight: 800; font-size: 14px; border-radius: 12px; border: none; cursor: pointer; white-space: nowrap; }
.v2-lead-note { margin: 9px 0 0; font-size: 11.5px; color: var(--text-3, #94a3b8); text-align: center; }
/* Đang khoá số liệu → ẩn dải cam kết + phễu vẫn hiện (thu SĐT), ảnh chia sẻ ẩn */
.cmp-gated .v2-exp { display: none; }
@media (max-width: 640px) {
	.v2-stats { flex-direction: row; flex-wrap: wrap; }
	.v2-stat { flex: 1 1 45%; }
	/* Mỗi hạng mục 2 dòng: tên nguyên dòng trên, giá + nhãn dòng dưới (tránh gãy chữ) */
	.v2-items-h { display: none; }
	.v2-row { font-size: 13px; padding: 10px 14px; }
	.v2-row .c1 { flex: 1 1 100%; padding-right: 0; margin-bottom: 5px; }
	.v2-row .c2 { width: auto; flex: 1; text-align: left; font-weight: 700; color: #0f172a; }
	.v2-row .c3 { width: auto; }
	.v2-items { margin: 0 14px; }
	.v2-card .cmp-zalo-gate { margin: 0 14px 14px; }
	.v2-stats { padding: 0 14px 14px; }
	.v2-hd { padding: 16px 14px 10px; }
	.v2-title { margin: 4px 14px 0; font-size: 18px; }
	.v2-sub { margin: 4px 14px 12px; }
	.v2-warnline, .v2-concl { margin-left: 14px; margin-right: 14px; }
	.v2-foot { padding: 12px 14px 16px; font-size: 11px; }
	.v2-exp { font-size: 11.5px; }
	.v2-cta { width: 100%; margin-left: 0; padding: 9px; }
	.v2-opts { flex-direction: column; }
	.v2-lead { padding: 16px 15px; }
	.v2-lead-form { flex-direction: column; }
	.v2-go { width: 100%; }
	.v2-badge { display: none; }
}

/* ===== Modal Đăng ký / Đăng nhập (mở khi khách chọn tệp check) ===== */
.dk-overlay { position: fixed; inset: 0; z-index: 9999; background: rgba(2, 6, 23, .55); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 18px; }
.dk-overlay[hidden] { display: none; }

/* Cổng vào NHẸ — chỉ hỏi tên */
.nmg-overlay { position: fixed; inset: 0; z-index: 9999; background: rgba(2, 6, 23, .55); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 18px; }
.nmg-overlay[hidden] { display: none; }
.nmg-box { position: relative; width: 100%; max-width: 380px; background: #fff; border-radius: 22px; padding: 26px 24px 20px; box-shadow: 0 24px 70px rgba(2, 6, 23, .35); text-align: center; animation: dk-pop .22s ease; }
.nmg-x { position: absolute; top: 12px; right: 14px; width: 30px; height: 30px; border: none; background: #f1f5f9; border-radius: 50%; font-size: 18px; color: #64748b; cursor: pointer; line-height: 1; }
.nmg-x:hover { background: #e2e8f0; color: #0f172a; }
.nmg-ic { font-size: 40px; line-height: 1; margin-bottom: 8px; }
.nmg-box h3 { font-size: 19px; color: var(--text-1, #0f172a); margin-bottom: 6px; }
.nmg-sub { font-size: 13.5px; color: var(--text-2, #475569); margin-bottom: 16px; line-height: 1.5; }
.nmg-form { display: flex; flex-direction: column; gap: 10px; }
.nmg-form input { height: 50px; border: 1.6px solid var(--border-2, #cbd5e1); border-radius: 12px; padding: 0 16px; font-family: inherit; font-size: 15.5px; color: var(--text-1, #0f172a); outline: none; text-align: center; }
.nmg-form input:focus { border-color: #16a34a; }
.nmg-go { height: 50px; border: none; border-radius: 12px; background: #16a34a; color: #fff; font-size: 15.5px; font-weight: 800; cursor: pointer; box-shadow: 0 8px 20px rgba(22, 163, 74, .32); }
.nmg-go:hover { background: #15803d; }
.nmg-msg { margin-top: 9px; font-size: 13px; font-weight: 600; color: #d4472b; }
.nmg-msg[hidden] { display: none; }
.nmg-foot { margin-top: 14px; font-size: 11.5px; color: var(--text-3, #94a3b8); line-height: 1.5; }
.nmg-foot b { color: #16a34a; }
.dk-modal { position: relative; width: 100%; max-width: 400px; background: #fff; border-radius: 22px; padding: 22px 22px 18px; box-shadow: 0 24px 70px rgba(2, 6, 23, .35); animation: dk-pop .22s ease; }
@keyframes dk-pop { from { transform: translateY(14px) scale(.97); opacity: 0; } to { transform: none; opacity: 1; } }
.dk-x { position: absolute; top: 10px; right: 12px; width: 34px; height: 34px; border: none; background: #f1f5f9; border-radius: 50%; font-size: 20px; color: #64748b; cursor: pointer; line-height: 1; }
.dk-x:hover { background: #e2e8f0; }
.dk-head { display: flex; align-items: center; gap: 10px; }
.dk-logo { width: 40px; height: 40px; border-radius: 11px; background: #16a34a; color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 22px; flex: 0 0 auto; }
.dk-head b { font-size: 15.5px; color: #0f172a; letter-spacing: .3px; }
.dk-head em { display: block; font-style: normal; font-size: 12px; color: #16a34a; font-weight: 600; }
.dk-sub { margin: 10px 0 12px; font-size: 13px; color: var(--text-2, #64748b); line-height: 1.55; }
.dk-tabs { display: flex; gap: 6px; background: #f1f5f9; border-radius: 12px; padding: 4px; margin-bottom: 14px; }
.dk-tab { flex: 1; padding: 9px; border: none; border-radius: 9px; background: transparent; font-size: 13.5px; font-weight: 700; color: #64748b; cursor: pointer; }
.dk-tab.is-on { background: #fff; color: #16a34a; box-shadow: 0 1px 4px rgba(2, 6, 23, .08); }
.dk-tabs[hidden] { display: none; }
.dk-form { display: flex; flex-direction: column; gap: 10px; }
.dk-form[hidden] { display: none; }
.dk-form input { height: 46px; border: 1.5px solid #d0d5dd; border-radius: 12px; padding: 0 14px; font-size: 15px; }
.dk-form input:focus { border-color: #16a34a; outline: none; box-shadow: 0 0 0 3px rgba(22, 163, 74, .12); }
.dk-types { display: flex; gap: 8px; }
.dk-type { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 10px 4px; border: 1.5px solid #e2e8f0; border-radius: 12px; background: #fff; font-size: 18px; cursor: pointer; color: #475569; }
.dk-type span { font-size: 11px; font-weight: 700; }
.dk-type.is-on { border-color: #16a34a; background: #f0fdf4; color: #14532d; box-shadow: 0 0 0 3px rgba(22, 163, 74, .10); }
.dk-go { height: 48px; border: none; border-radius: 12px; background: #16a34a; color: #fff; font-size: 15px; font-weight: 800; cursor: pointer; box-shadow: 0 4px 14px rgba(22, 163, 74, .35); }
.dk-go:hover { background: #15803d; }
.dk-note { margin: 2px 0 0; font-size: 12px; color: var(--text-3, #94a3b8); text-align: center; }
.dk-note a { color: #16a34a; font-weight: 700; }
.dk-msg { margin: 10px 0 0; font-size: 13px; text-align: center; min-height: 18px; }
.dk-msg.is-err { color: #b91c1c; }
.dk-msg.is-ok { color: #15803d; }
.dk-foot { margin: 10px 0 0; font-size: 11.5px; color: var(--text-3, #94a3b8); text-align: center; line-height: 1.5; }
.dk-success { text-align: center; padding: 6px 0 2px; }
.dk-success[hidden] { display: none; }
.dk-success-ic { width: 64px; height: 64px; margin: 4px auto 12px; border-radius: 50%; background: #16a34a; color: #fff; font-size: 34px; font-weight: 900; display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 20px rgba(22, 163, 74, .35); animation: dk-pop .3s ease; }
.dk-success h4 { margin: 0 0 6px; font-size: 18px; color: #0f172a; }
.dk-success p { margin: 0 0 14px; font-size: 13.5px; color: var(--text-2, #64748b); line-height: 1.6; }
.dk-success .dk-go { width: 100%; }
[data-dropzone].is-pulse { animation: cn-pulse 1.5s ease; border-color: #16a34a !important; }

/* Ảnh chia sẻ kết quả check (đăng nhóm FB/Zalo) */
.cmp-share { margin-top: 18px; text-align: center; }
.cmp-share-btn { display: inline-flex; align-items: center; gap: 8px; background: #16a34a; color: #fff; font-weight: 800; font-size: 15px; padding: 12px 24px; border-radius: 12px; border: none; cursor: pointer; box-shadow: 0 4px 14px rgba(22, 163, 74, .35); }
.cmp-share-btn:hover { background: #15803d; }
.cmp-share-sub { margin: 8px auto 0; max-width: 520px; font-size: 12.5px; color: var(--text-3, #94a3b8); }
.cmp-share-out { margin-top: 14px; }
.cmp-share-out[hidden] { display: none; }
.cmp-share-img { max-width: 100%; width: 430px; border-radius: 16px; box-shadow: 0 10px 30px rgba(2, 6, 23, .25); }
.cmp-share-actions { display: flex; gap: 10px; justify-content: center; margin-top: 12px; flex-wrap: wrap; }
.cmp-share-dl, .cmp-share-send { display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border-radius: 11px; font-weight: 700; font-size: 14px; cursor: pointer; text-decoration: none; border: none; }
.cmp-share-dl { background: #0f172a; color: #fff; }
.cmp-share-send { background: #2563eb; color: #fff; }
.cmp-share-send[hidden] { display: none; }
.cmp-gated .cmp-share { display: none; } /* Đang khoá số liệu → chưa cho tạo ảnh */
.cmp-disc .icon { width: 15px; height: 15px; flex: 0 0 auto; margin-top: 1px; }

/* ===== So sánh báo giá nhiều đơn vị — cards mobile-first ===== */
.cmp2 { display: flex; flex-direction: column; gap: 16px; }
.cmp2-top { background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; padding: 18px; box-shadow: 0 2px 10px rgba(16,24,40,.05); }
.cmp2-top-head h3 { margin: 0; font-size: 19px; font-weight: 800; }
.cmp2-top-head p { margin: 4px 0 0; font-size: 13px; color: var(--text-2); line-height: 1.5; }
.cmp2-units { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.cmp2-unit { font-size: 13px; font-weight: 700; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border-2); background: #f8fafc; }
.cmp2-unit.u-0 { color: #2563eb; border-color: #bfdbfe; background: #eff6ff; }
.cmp2-unit.u-1 { color: #16a34a; border-color: #bbf7d0; background: #f0fdf4; }
.cmp2-unit.u-2 { color: #7c3aed; border-color: #ddd6fe; background: #f5f3ff; }
.cmp2-unit.u-3 { color: #ea580c; border-color: #fed7aa; background: #fff7ed; }
.cmp2-unit.u-4 { color: #0d9488; border-color: #99f6e4; background: #f0fdfa; }
.cmp2-cards { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media ( min-width: 720px ) { .cmp2-cards { grid-template-columns: 1fr 1fr; } }
.cmp2-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; padding: 16px; box-shadow: 0 2px 8px rgba(16,24,40,.05); }
.cmp2-card-h { display: flex; align-items: center; gap: 9px; margin-bottom: 12px; }
.cmp2-ic { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 9px; background: var(--brand-bg); color: var(--brand); }
.cmp2-ic .icon { width: 18px; height: 18px; }
.cmp2-card-h h5 { margin: 0; font-size: 15.5px; font-weight: 700; }
.cmp2-vals { display: flex; flex-direction: column; gap: 8px; }
.cmp2-val { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 9px 12px; border-radius: 10px; background: #f8fafc; border-left: 3px solid #e5e7eb; }
.cmp2-val-u { font-size: 12.5px; font-weight: 700; flex: 0 0 auto; }
.cmp2-val-u.u-0 { color: #2563eb; } .cmp2-val-u.u-1 { color: #16a34a; } .cmp2-val-u.u-2 { color: #7c3aed; } .cmp2-val-u.u-3 { color: #ea580c; } .cmp2-val-u.u-4 { color: #0d9488; }
.cmp2-val:nth-child(1) { border-left-color: #93c5fd; } .cmp2-val:nth-child(2) { border-left-color: #86efac; } .cmp2-val:nth-child(3) { border-left-color: #c4b5fd; } .cmp2-val:nth-child(4) { border-left-color: #fdba74; } .cmp2-val:nth-child(5) { border-left-color: #5eead4; }
.cmp2-val-v { font-size: 13.5px; font-weight: 600; color: var(--text-1); text-align: right; line-height: 1.4; }
.cmp2-note { display: flex; gap: 7px; align-items: flex-start; margin: 12px 0 0; padding: 10px 12px; background: #fffbeb; border: 1px solid #fde68a; border-radius: 10px; font-size: 12.5px; color: #92400e; line-height: 1.5; }
.cmp2-note-ic { flex: 0 0 auto; }
.cmp2-concl { display: flex; gap: 11px; align-items: flex-start; padding: 14px 16px; background: #eff6ff; border: 1px solid #dbeafe; border-radius: 14px; }
.cmp2-concl-ic { font-size: 20px; flex: 0 0 auto; line-height: 1; }
.cmp2-concl b { display: block; font-size: 13px; color: #1d4ed8; margin-bottom: 3px; }
.cmp2-concl p { margin: 0; font-size: 13.5px; color: var(--text-1); line-height: 1.6; }

/* ===== Tin tức & bài viết (SEO) — mobile-first, card-based ===== */
.crumb { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text-3); margin: 0 0 14px; }
.crumb a { color: var(--text-2); }
.crumb a:hover { color: var(--brand); }
.crumb-sep { color: #cbd5e1; }
.crumb [aria-current="page"] { color: var(--text-1); font-weight: 600; }

.news { display: flex; flex-direction: column; }
.news-head { margin-bottom: 18px; }
.news-head h1 { margin: 0; font-size: 24px; font-weight: 800; line-height: 1.25; }
.news-head p { margin: 10px 0 0; font-size: 14px; color: var(--text-2); line-height: 1.6; max-width: 760px; }
.news-sec-title { margin: 6px 0 14px; font-size: 18px; font-weight: 800; color: var(--text-1); }
.news-home .news-grid { margin-top: 6px; }
.act-cta { display: inline-block; margin-top: 8px; font-size: 12.5px; font-weight: 600; color: var(--brand); }
a.project-card:hover .act-cta { text-decoration: underline; }
/* Ảnh báo giá đã làm mờ (an toàn) */
.act-blur { width: 100%; height: 100%; object-fit: cover; filter: blur(3px); transform: scale(1.06); }
.act-doc { margin: 4px 0 20px; }
.act-doc-img { width: 100%; max-height: 240px; object-fit: cover; border-radius: 14px; filter: blur(4px); transform: scale(1.04); display: block; }
.act-doc figcaption { margin-top: 8px; font-size: 12.5px; color: var(--text-3); text-align: center; }

/* Thẻ hoạt động dạng text (thay ảnh blur) */
.act-card { display: flex; flex-direction: column; text-decoration: none; color: inherit; }
.act-card-head { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.act-card-emoji { flex: none; width: 34px; height: 34px; display: grid; place-items: center; font-size: 18px; line-height: 1; border-radius: 10px; }
.act-card-head h3 { font-size: 14.5px; margin: 0; }
.act-card-info { list-style: none; margin: 0 0 4px; padding: 0; display: flex; flex-direction: column; gap: 5px; }
.act-card-info li { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--text-2); line-height: 1.35; }
.act-card-info li.act-money { font-weight: 700; color: var(--text-1); }
.act-info-ic { flex: none; font-size: 13px; opacity: .9; }
.btn-soft { display: inline-flex; align-items: center; gap: 6px; padding: 9px 18px; border-radius: 10px; font-size: 13.5px; font-weight: 600; color: var(--brand); background: var(--brand-bg); border: 1px solid #c7d2fe; }
.btn-soft:hover { background: #e0e7ff; }
/* Thanh "Hỏi AI về kết quả này" */
.ask-ai-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 18px 0; padding: 14px 18px; border-radius: 14px; background: linear-gradient(135deg, #ecfeff, #eff6ff); border: 1px solid #bae6fd; }
.ask-ai-text { font-size: 14px; font-weight: 600; color: var(--text-1, #0f172a); }
.btn-ask-ai { display: inline-flex; align-items: center; gap: 7px; padding: 10px 18px; border: none; border-radius: 10px; cursor: pointer; font-size: 13.5px; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--brand, #16a34a), #0ea5e9); box-shadow: 0 6px 16px rgba(2, 6, 23, .14); }
.btn-ask-ai:hover { transform: translateY(-1px); box-shadow: 0 10px 22px rgba(2, 6, 23, .2); }
.btn-ask-ai svg { width: 17px; height: 17px; }

/* CTA giới thiệu đơn vị thiết kế 3D (sau khi check 3D) */
.cta3d-neutral { display: flex; gap: 9px; align-items: flex-start; margin: 18px 0 0; padding: 13px 16px; border-radius: 12px; background: #f0fdf4; border: 1px solid #bbf7d0; font-size: 13.5px; line-height: 1.55; color: #166534; }
.cta3d-neutral b { color: #14532d; }
.cta3d { position: relative; overflow: hidden; margin: 20px 0 0; padding: 24px 22px; border-radius: 20px; color: #fff; background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 48%, #db2777 100%); box-shadow: 0 18px 40px rgba(79, 70, 229, .28); }
.cta3d-glow { position: absolute; top: -60px; right: -40px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,.35), rgba(255,255,255,0) 70%); pointer-events: none; }
.cta3d-inner { position: relative; z-index: 1; }
.cta3d-badge { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .3px; padding: 5px 12px; border-radius: 999px; background: rgba(255,255,255,.18); border: 1px solid rgba(255,255,255,.35); backdrop-filter: blur(2px); }
.cta3d-title { margin: 12px 0 6px; font-size: 20px; line-height: 1.3; font-weight: 800; color: #fff; }
.cta3d-title span { background: rgba(255,255,255,.22); padding: 0 8px; border-radius: 7px; white-space: nowrap; }
.cta3d-sub { margin: 0 0 14px; font-size: 14px; line-height: 1.6; color: rgba(255,255,255,.92); max-width: 640px; }
.cta3d-feats { list-style: none; margin: 0 0 18px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 9px 18px; }
.cta3d-feats li { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; line-height: 1.4; color: #fff; font-weight: 500; }
.cta3d-feat-ic { flex: none; font-size: 15px; line-height: 1.3; }
.cta3d-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.cta3d-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 22px; border-radius: 12px; font-size: 14.5px; font-weight: 800; font-family: inherit; text-decoration: none; border: 0; cursor: pointer; transition: transform .12s, box-shadow .12s; }
.cta3d-zalo { color: #1e1b4b; background: #fff; box-shadow: 0 8px 20px rgba(2, 6, 23, .22); }
.cta3d-call { color: #fff; background: rgba(255,255,255,.16); border: 1.5px solid rgba(255,255,255,.55); }
.cta3d-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(2, 6, 23, .3); }
.cta3d-note { margin: 12px 0 0; font-size: 12.5px; color: rgba(255,255,255,.82); }

/* Form Họ tên + SĐT trong bài bán hàng 3D (hiện sau khi bấm nút) */
.cta3d-form { display: flex; flex-direction: column; gap: 11px; margin: 2px 0 0; }
.cta3d-form[hidden] { display: none; }
.cta3d-form-h { margin: 0; font-size: 13.5px; font-weight: 600; color: rgba(255,255,255,.96); }
.cta3d-form-row { display: flex; gap: 10px; flex-wrap: wrap; }
.cta3d-form-row input { flex: 1 1 180px; min-width: 0; font-family: inherit; font-size: 14px; padding: 12px 14px; border-radius: 11px; border: 1px solid rgba(255,255,255,.55); background: rgba(255,255,255,.97); color: #1e1b4b; outline: none; }
.cta3d-form-row input::placeholder { color: #94a3b8; }
.cta3d-form-row input:focus { border-color: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.28); }
.cta3d-form-go { align-self: flex-start; border: 0; cursor: pointer; font-family: inherit; font-weight: 800; font-size: 14.5px; padding: 12px 26px; border-radius: 12px; background: #fff; color: #4f46e5; box-shadow: 0 8px 20px rgba(2, 6, 23, .22); transition: transform .12s, filter .12s; }
.cta3d-form-go:hover { transform: translateY(-2px); filter: brightness(.98); }
.cta3d-lead-result { margin: 9px 0 0; font-size: 13px; font-weight: 600; color: #fff; }
.cta3d-lead-result.is-err { color: #fde68a; }
.cta3d-lead-result.is-ok { color: #fff; }
@media (max-width: 560px) {
	.cta3d-feats { grid-template-columns: 1fr; }
	.cta3d-title { font-size: 18px; }
	.cta3d-btn { flex: 1 1 auto; justify-content: center; }
	.cta3d-form-go { align-self: stretch; }
}

/* Cảnh báo tải nhầm loại tài liệu */
.doc-mismatch { text-align: center; padding: 28px 22px; border-radius: 18px; background: linear-gradient(135deg, #fff7ed, #fef2f2); border: 1px solid #fed7aa; }
.doc-mismatch-ic { font-size: 40px; line-height: 1; }
.doc-mismatch h3 { margin: 10px 0 6px; font-size: 19px; font-weight: 800; color: #9a3412; }
.doc-mismatch p { margin: 0 auto; max-width: 560px; font-size: 14.5px; line-height: 1.6; color: var(--text-2, #475569); }
.doc-mismatch-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin: 18px 0 6px; }
.doc-mismatch-note { font-size: 12.5px; color: var(--text-3, #94a3b8); margin-top: 8px; }

/* Banner "đã tự chuyển công cụ" (tải nhầm → hệ thống điều hướng, kết quả đúng ở dưới) */
.doc-reroute { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; margin: 0 0 14px; border-radius: 14px; background: linear-gradient(135deg, #eff6ff, #ecfdf5); border: 1px solid #bfdbfe; }
.doc-reroute-ic { font-size: 26px; line-height: 1.2; flex: 0 0 auto; }
.doc-reroute-body { margin: 0; font-size: 14px; line-height: 1.6; color: var(--text-2, #475569); }
.doc-reroute-body strong { color: var(--text-1, #0f172a); }
.doc-reroute-body a { font-weight: 700; color: #1d4ed8; text-decoration: none; white-space: nowrap; }
.doc-reroute-body a:hover { text-decoration: underline; }
@media (max-width: 560px) {
	.doc-reroute { padding: 12px 13px; gap: 10px; }
	.doc-reroute-ic { font-size: 22px; }
	.doc-reroute-body { font-size: 13.5px; }
}

/* Khối nội dung SEO trang chủ */
.home-seo h2 { margin: 0 0 12px; font-size: 20px; font-weight: 800; line-height: 1.3; color: var(--text-1); }
/* FAQ cuối trang công cụ: canh theo CỘT NỘI DUNG (check-main), không tràn sang vùng sidebar */
.tool-faq { margin-top: 22px; max-width: 100%; box-sizing: border-box; }
@media ( min-width: 801px ) { .tool-faq { max-width: calc(100% - 322px); } }
.home-seo-subh { margin-top: 26px !important; }
.home-seo-body p { margin: 0 0 12px; font-size: 14.5px; line-height: 1.7; color: var(--text-2); }
.home-seo-body strong { color: var(--text-1); font-weight: 700; }
.home-faq .article-faq-item { margin-bottom: 10px; }
.news-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media ( min-width: 560px ) { .news-grid { grid-template-columns: 1fr 1fr; } }
@media ( min-width: 980px ) { .news-grid { grid-template-columns: 1fr 1fr 1fr; } }

.news-card { display: flex; flex-direction: column; background: #fff; border: 1px solid #e5e7eb; border-radius: 16px; overflow: hidden; box-shadow: 0 2px 10px rgba(16,24,40,.05); transition: transform .15s, box-shadow .15s; }
.news-card:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(16,24,40,.10); }
.news-card-cover { display: grid; place-items: center; height: 128px; text-decoration: none; overflow: hidden; }
.news-card-emoji { font-size: 46px; line-height: 1; filter: drop-shadow(0 4px 8px rgba(0,0,0,.12)); }
.news-card-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.news-card-body { display: flex; flex-direction: column; gap: 8px; padding: 15px 16px 16px; flex: 1 1 auto; }
.news-card-cat { align-self: flex-start; font-size: 11px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; color: var(--brand); background: var(--brand-bg); padding: 3px 10px; border-radius: 999px; }
.news-card-title { margin: 0; font-size: 16px; font-weight: 700; line-height: 1.35; }
.news-card-title a { color: var(--text-1); }
.news-card-title a:hover { color: var(--brand); }
.news-card-ex { margin: 0; font-size: 13px; color: var(--text-2); line-height: 1.55; }
.news-card-meta { margin-top: auto; padding-top: 6px; display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--text-3); }
.news-card-dot { color: #cbd5e1; }

/* Cover gradient theo accent (đồng bộ màu module) */
.accent-green  { background: linear-gradient(135deg, #dcfce7, #86efac); }
.accent-blue   { background: linear-gradient(135deg, #dbeafe, #93c5fd); }
.accent-purple { background: linear-gradient(135deg, #ede9fe, #c4b5fd); }
.accent-rose   { background: linear-gradient(135deg, #ffe4e6, #fda4af); }
.accent-orange { background: linear-gradient(135deg, #ffedd5, #fdba74); }
.accent-amber  { background: linear-gradient(135deg, #fef3c7, #fcd34d); }
.accent-teal   { background: linear-gradient(135deg, #ccfbf1, #5eead4); }
.accent-indigo { background: linear-gradient(135deg, #e0e7ff, #a5b4fc); }

/* ----- Bài viết đơn ----- */
.article { max-width: 820px; }
.article-head { margin-bottom: 16px; }
.article-cat { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; color: var(--brand); background: var(--brand-bg); padding: 4px 11px; border-radius: 999px; }
.article-head h1 { margin: 12px 0 0; font-size: 27px; font-weight: 800; line-height: 1.25; }
.article-lead { margin: 12px 0 0; font-size: 15.5px; color: var(--text-2); line-height: 1.6; }
.article-meta { margin-top: 12px; display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-3); }
.article-cover { height: 180px; border-radius: 18px; display: grid; place-items: center; margin: 4px 0 22px; overflow: hidden; }
.article-cover-emoji { font-size: 70px; line-height: 1; filter: drop-shadow(0 6px 14px rgba(0,0,0,.14)); }
.article-cover-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.article-cover-top { height: 120px; margin: 6px 0 18px; position: relative; }
.article-cover-top .article-cover-img { opacity: .82; }
.article-cover-top::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(255,255,255,.12) 0%, rgba(255,255,255,0) 35%, rgba(255,255,255,.55) 100%); pointer-events: none; }

.article-body { font-size: 15.5px; line-height: 1.75; color: var(--text-1); }
.article-body h2 { margin: 30px 0 10px; font-size: 21px; font-weight: 800; line-height: 1.3; }
.article-body h3 { margin: 22px 0 8px; font-size: 17px; font-weight: 700; }
.article-body p { margin: 0 0 14px; }
.article-body ul, .article-body ol { margin: 0 0 16px; padding-left: 4px; list-style: none; }
.article-body li { position: relative; padding-left: 22px; margin-bottom: 8px; line-height: 1.65; }
.article-body ul li::before { content: ""; position: absolute; left: 4px; top: 10px; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); }
.article-body ol { counter-reset: cn; }
.article-body ol li { counter-increment: cn; }
.article-body ol li::before { content: counter(cn); position: absolute; left: 0; top: 1px; width: 18px; height: 18px; font-size: 11px; font-weight: 700; display: grid; place-items: center; border-radius: 50%; background: var(--brand-bg); color: var(--brand); }
.article-body a { color: var(--brand); font-weight: 600; text-decoration: underline; text-decoration-color: #c7d2fe; text-underline-offset: 2px; }
.article-body a:hover { text-decoration-color: var(--brand); }
.article-body strong { font-weight: 700; color: var(--text-1); }
/* Ảnh trong bài: vừa khung, không tràn/quá cao — căn giữa, bo góc cho dễ nhìn */
.article-body img { display: block; max-width: 100%; width: auto; height: auto; max-height: 520px; margin: 20px auto; border-radius: 12px; border: 1px solid var(--border-2); box-shadow: 0 2px 10px rgba(16,24,40,.06); }
.article-body figure { margin: 20px 0; text-align: center; }
.article-body figure img { margin: 0 auto 8px; }
.article-body figcaption { font-size: 12.5px; color: var(--text-3); text-align: center; line-height: 1.5; }
@media (max-width: 560px) { .article-body img { max-height: 360px; border-radius: 10px; margin: 16px auto; } }

.article-faq { margin-top: 30px; }
.article-faq > h2 { margin: 0 0 12px; font-size: 21px; font-weight: 800; }
.article-faq-item { border: 1px solid #e5e7eb; border-radius: 12px; padding: 0 16px; margin-bottom: 10px; background: #fff; }
.article-faq-item summary { list-style: none; cursor: pointer; padding: 14px 0; font-size: 15px; font-weight: 700; color: var(--text-1); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.article-faq-item summary::-webkit-details-marker { display: none; }
.article-faq-item summary::after { content: "+"; font-size: 20px; font-weight: 400; color: var(--brand); flex: 0 0 auto; }
.article-faq-item[open] summary::after { content: "−"; }
.article-faq-item p { margin: 0 0 14px; font-size: 14px; color: var(--text-2); line-height: 1.65; }

.article-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0 0; }
.article-tag { font-size: 12px; font-weight: 600; color: var(--text-2); background: #f1f5f9; border-radius: 999px; padding: 5px 12px; }

.article-cta { display: flex; flex-direction: column; gap: 14px; margin: 26px 0; padding: 20px; border-radius: 18px; background: linear-gradient(135deg, #eef2ff, #f5f3ff); border: 1px solid #c7d2fe; }
.article-cta h3 { margin: 0; font-size: 18px; font-weight: 800; }
.article-cta p { margin: 6px 0 0; font-size: 13.5px; color: var(--text-2); line-height: 1.6; }
.article-cta .btn-primary { align-self: flex-start; }
@media ( min-width: 640px ) { .article-cta { flex-direction: row; align-items: center; justify-content: space-between; } .article-cta .btn-primary { flex: 0 0 auto; } }

.article-related { margin-top: 30px; }
.article-related > h2 { margin: 0 0 14px; font-size: 21px; font-weight: 800; }
.article-back { margin: 24px 0 0; }
.article-back a { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; font-weight: 600; color: var(--brand); }
.article-back a .icon { width: 16px; height: 16px; transform: rotate(180deg); }

@media ( max-width: 600px ) {
	.news-head h1 { font-size: 21px; }
	.article-head h1 { font-size: 23px; }
	.article-body { font-size: 15px; }
	.article-body h2 { font-size: 19px; }
	.article-cover { height: 150px; }
	.article-cover-top { height: 95px; }
	.article-cover-emoji { font-size: 58px; }
}

/* ===== Trang đích (landing) — Nhận báo giá chuẩn ===== */
body.view-nhan-bao-gia-chuan .sidebar,
body.view-nhan-bao-gia-chuan .topbar,
body.view-nhan-bao-gia-chuan .sidebar-toggle { display: none !important; }
body.view-nhan-bao-gia-chuan .content { padding: 0; max-width: none; }
body.view-nhan-bao-gia-chuan .main { background: linear-gradient(180deg, #f8fafc, #eef2ff); min-height: 100vh; }

.lp { max-width: 1080px; margin: 0 auto; padding: 18px 20px 48px; }
.lp-brand { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 6px 0 24px; }
.lp-brand-link { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 17px; color: var(--text-1); }
.lp-brand-link img { border-radius: 8px; }
.lp-brand-cta { font-size: 13px; font-weight: 700; color: var(--brand); background: var(--brand-bg); padding: 8px 14px; border-radius: 999px; }

.lp-grid { display: grid; grid-template-columns: 1fr; gap: 22px; align-items: start; }
@media ( min-width: 880px ) { .lp-grid { grid-template-columns: 1.1fr .9fr; gap: 34px; } }

.lp-eyebrow { display: inline-block; font-size: 13px; font-weight: 700; color: #15803d; background: #dcfce7; padding: 6px 14px; border-radius: 999px; }
.lp-title { margin: 14px 0 0; font-size: 30px; line-height: 1.2; font-weight: 800; letter-spacing: -.01em; }
.lp-title .hl { color: var(--brand); }
.lp-lead { margin: 14px 0 0; font-size: 16px; line-height: 1.65; color: var(--text-2); }

.lp-benefits { list-style: none; margin: 22px 0 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.lp-benefits li { display: flex; gap: 12px; align-items: flex-start; }
.lp-bi { flex: 0 0 auto; font-size: 18px; line-height: 1.3; }
.lp-benefits b { display: block; font-size: 15px; color: var(--text-1); }
.lp-benefits p { margin: 2px 0 0; font-size: 13.5px; color: var(--text-2); line-height: 1.55; }

.lp-trust { display: flex; gap: 9px; align-items: flex-start; margin: 24px 0 0; padding: 13px 15px; background: #fff; border: 1px solid #e5e7eb; border-radius: 12px; font-size: 13px; color: var(--text-2); line-height: 1.55; }
.lp-trust .icon { width: 18px; height: 18px; color: #16a34a; flex: 0 0 auto; margin-top: 1px; }

.lp-form-card { background: #fff; border: 1px solid #e5e7eb; border-radius: 20px; padding: 24px; box-shadow: 0 14px 40px rgba(16,24,40,.10); position: sticky; top: 18px; }
.lp-form-title { margin: 0; font-size: 21px; font-weight: 800; }
.lp-form-sub { margin: 6px 0 18px; font-size: 13.5px; color: var(--text-2); line-height: 1.5; }
.lp-form { gap: 12px; }
.lp-form input, .lp-select { height: 50px; border: 1px solid var(--border-2); border-radius: 12px; padding: 0 15px; font-size: 15px; background: #fff; width: 100%; }
.lp-form input:focus, .lp-select:focus { border-color: var(--brand); outline: none; }
.lp-select { color: var(--text-2); appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2.5'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 15px center; padding-right: 38px; }
.lp-form .btn-primary { height: 52px; font-size: 15.5px; font-weight: 700; margin-top: 2px; }
.lp-form-note { margin: 14px 0 0; font-size: 12px; color: var(--text-3); text-align: center; }

.lp-reveal { margin-top: 8px; padding: 20px; text-align: center; background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 16px; }
.lp-reveal-ic { font-size: 34px; line-height: 1; }
.lp-reveal h3 { margin: 8px 0 14px; font-size: 18px; font-weight: 800; color: #15803d; }
.lp-reveal .btn-primary { height: 50px; }
.lp-reveal-note { margin: 12px 0 0; font-size: 13px; color: var(--text-2); line-height: 1.55; }

.lp-foot { margin: 30px 0 0; text-align: center; font-size: 14px; color: var(--text-2); }
.lp-foot a { color: var(--brand); font-weight: 600; }

@media ( max-width: 600px ) {
	.lp-title { font-size: 25px; }
	.lp-lead { font-size: 15px; }
	.lp-form-card { position: static; padding: 20px; }
}

/* ===== Lead magnet "Nhận báo giá chuẩn" quanh trang check ===== */
.bgc { margin: 16px 0 0; padding: 16px 18px; border-radius: 16px; background: linear-gradient(135deg, #ecfdf5, #eff6ff); border: 1px solid #bbf7d0; }
.bgc-head { display: flex; gap: 12px; align-items: flex-start; }
.bgc-ic { font-size: 24px; line-height: 1; flex: 0 0 auto; }
.bgc-head-text h3 { margin: 0; font-size: 15.5px; font-weight: 800; line-height: 1.3; }
.bgc-head-text p { margin: 5px 0 0; font-size: 13px; color: var(--text-2); line-height: 1.55; }
.bgc-form { flex-direction: row; flex-wrap: wrap; gap: 9px; margin-top: 13px; }
.bgc-form input { flex: 1 1 160px; height: 44px; border: 1px solid var(--border-2); border-radius: 11px; padding: 0 13px; font-size: 14px; background: #fff; min-width: 0; }
.bgc-form input:focus { border-color: var(--brand); outline: none; }
.bgc-form button { flex: 0 0 auto; width: auto; height: 44px; white-space: nowrap; }
.bgc-form .btn-label { white-space: nowrap; }
.bgc-btn { margin-top: 13px; width: auto; display: inline-flex; }
.bgc-link { background: linear-gradient(135deg, #eff6ff, #f5f3ff); border-color: #c7d2fe; }
.bgc-link .bgc-head { align-items: center; }
.bgc-reveal { margin-top: 13px; padding: 14px; text-align: center; background: #fff; border: 1px solid #bbf7d0; border-radius: 12px; }
.bgc-reveal-t { display: block; font-size: 14px; font-weight: 700; color: #15803d; margin-bottom: 10px; }
.bgc-reveal-note { margin: 0; font-size: 13px; color: var(--text-2); line-height: 1.55; }
/* Landing chuyển đổi cuối Check báo giá (mẫu C) — tông cam ấm, nổi bật */
.bgc-detail { margin-top: 22px; padding: 22px 20px; border: 1.5px solid #fdba74; background: linear-gradient(135deg, #fff7ed, #fefce8); box-shadow: 0 10px 26px rgba(249,115,22,.15); }
.bgc-detail .bgc-ic { font-size: 28px; }
.bgc-detail .bgc-head-text h3 { font-size: 17.5px; }
.bgc-detail .bgc-head-text p { font-size: 13.5px; }
.bgc-trust { margin: 11px 0 0; font-size: 12.5px; color: #9a3412; line-height: 1.5; }
@media ( min-width: 720px ) {
	.bgc-link { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
	.bgc-link .bgc-btn { margin-top: 0; flex: 0 0 auto; }
}
@media ( max-width: 520px ) {
	.bgc-form button { flex: 1 1 100%; width: 100%; }
}

/* ===== Widget chat AI nổi (bong bóng góc phải) ===== */
.chatfab { position: fixed; right: 18px; bottom: 18px; z-index: 9999; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.chatfab-btn { position: relative; width: 58px; height: 58px; border: none; border-radius: 50%; cursor: pointer; color: #fff; background: linear-gradient(135deg, var(--brand, #16a34a), #0ea5e9); box-shadow: 0 12px 28px rgba(2, 6, 23, .28); display: grid; place-items: center; transition: transform .18s ease, box-shadow .18s ease; }
.chatfab-btn:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 16px 34px rgba(2, 6, 23, .34); }
.chatfab-btn svg { width: 26px; height: 26px; }
.chatfab-ic { display: grid; place-items: center; }
.chatfab-ic-close { display: none; }
.chatfab.is-open .chatfab-ic-open { display: none; }
.chatfab.is-open .chatfab-ic-close { display: grid; }
.chatfab-pulse { position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 0 0 0 rgba(22, 163, 74, .5); animation: chatfabPulse 2.4s ease-out infinite; }
.chatfab.is-open .chatfab-pulse { display: none; }
/* Bong bóng mời chat chủ động */
.chatfab-teaser { position: relative; max-width: 250px; background: #fff; border: 1px solid var(--border, #e5e7eb); border-radius: 14px; box-shadow: 0 12px 28px rgba(2, 6, 23, .18); padding: 12px 32px 12px 14px; font-size: 13px; line-height: 1.5; color: var(--text-1, #0f172a); cursor: pointer; animation: chatfabTeaserIn .25s ease; }
.chatfab-teaser strong { color: var(--brand, #16a34a); }
.chatfab-teaser::after { content: ""; position: absolute; right: 22px; bottom: -7px; width: 14px; height: 14px; background: #fff; border-right: 1px solid var(--border, #e5e7eb); border-bottom: 1px solid var(--border, #e5e7eb); transform: rotate(45deg); }
.chatfab-teaser-x { position: absolute; top: 4px; right: 6px; width: 20px; height: 20px; border: none; background: transparent; color: var(--text-3, #94a3b8); font-size: 18px; line-height: 1; cursor: pointer; border-radius: 6px; }
.chatfab-teaser-x:hover { background: #f1f5f9; color: var(--text-1, #0f172a); }
@keyframes chatfabTeaserIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes chatfabPulse { 0% { box-shadow: 0 0 0 0 rgba(22, 163, 74, .5); } 70% { box-shadow: 0 0 0 16px rgba(22, 163, 74, 0); } 100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); } }

.chatfab-panel { display: none; width: 360px; max-width: calc(100vw - 36px); height: 520px; max-height: calc(100vh - 110px); background: #fff; border: 1px solid var(--border, #e5e7eb); border-radius: 18px; box-shadow: 0 24px 60px rgba(2, 6, 23, .26); flex-direction: column; overflow: hidden; transform-origin: bottom right; }
.chatfab.is-open .chatfab-panel { display: flex; animation: chatfabIn .18s ease; }
@keyframes chatfabIn { from { opacity: 0; transform: translateY(10px) scale(.97); } to { opacity: 1; transform: none; } }
.chatfab-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; color: #fff; background: linear-gradient(135deg, var(--brand, #16a34a), #0ea5e9); }
.chatfab-ava { width: 34px; height: 34px; flex: 0 0 auto; border-radius: 50%; background: rgba(255, 255, 255, .18); display: grid; place-items: center; }
.chatfab-ava svg { width: 19px; height: 19px; }
.chatfab-head-text { flex: 1 1 auto; line-height: 1.25; }
.chatfab-head-text strong { display: block; font-size: 14.5px; }
.chatfab-head-text small { font-size: 11.5px; opacity: .9; }
.chatfab-close { flex: 0 0 auto; width: 30px; height: 30px; border: none; border-radius: 8px; background: rgba(255, 255, 255, .16); color: #fff; cursor: pointer; display: grid; place-items: center; }
.chatfab-close:hover { background: rgba(255, 255, 255, .28); }
.chatfab-close svg { width: 17px; height: 17px; }
.chatfab-thread { flex: 1 1 auto; overflow-y: auto; padding: 14px; background: var(--bg-soft, #f8fafc); }
.chatfab-suggest { display: flex; flex-wrap: wrap; gap: 7px; padding: 9px 12px 0; }
.chatfab-suggest .chip { font-size: 12px; }
.chatfab-input { display: flex; gap: 8px; padding: 11px 12px; border-top: 1px solid var(--border, #e5e7eb); background: #fff; }
.chatfab-input input { flex: 1 1 auto; height: 42px; border: 1px solid var(--border-2, #d1d5db); border-radius: 11px; padding: 0 13px; font-size: 14px; min-width: 0; }
.chatfab-input input:focus { border-color: var(--brand, #16a34a); outline: none; }
.chatfab-input button { flex: 0 0 auto; width: 42px; height: 42px; padding: 0; display: grid; place-items: center; }
.chatfab-input button svg { width: 18px; height: 18px; }

@media ( max-width: 480px ) {
	.chatfab { right: 14px; bottom: 14px; }
	.chatfab-panel { height: 70vh; }
}

/* ===== Trang đích báo giá (/bao-gia/) ===== */
.bgp { max-width: 920px; }
.bgp-range { margin: 4px 0 16px; font-size: 15px; color: var(--text-2); }
.bgp-range strong { color: #0f766e; }
.bgp-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.bgp-table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 520px; }
.bgp-table th, .bgp-table td { padding: 10px 12px; text-align: right; border-bottom: 1px solid var(--border, #e5e7eb); white-space: nowrap; }
.bgp-table thead th { background: linear-gradient(135deg, #0f766e, #14b8a6); color: #fff; font-weight: 700; border-bottom: none; }
.bgp-table th:first-child, .bgp-table td:first-child { text-align: left; white-space: normal; }
.bgp-table th:nth-child(2), .bgp-table td:nth-child(2) { text-align: center; }
.bgp-table tbody tr:nth-child(even) { background: #f8fafc; }
.bgp-table tbody tr:hover { background: #ecfdf5; }
.bgp-note { margin: 10px 0 0; font-size: 12.5px; color: var(--text-2); font-style: italic; }
.bgp-other { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.bgp-other li { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--border, #e5e7eb); font-size: 14px; }
.bgp-other strong { color: #0f766e; white-space: nowrap; }
.bgp-cta { background: linear-gradient(135deg, #ecfdf5, #f0fdfa); border: 1px solid #a7e0d8; }
.bgp-cta p { color: var(--text-2); margin: 0 0 14px; line-height: 1.6; }
.bgp-check-btn { display: inline-flex; }
.bgp-faq { padding: 10px 0; border-bottom: 1px solid var(--border, #e5e7eb); }
.bgp-faq:last-child { border-bottom: none; }
.bgp-faq h3 { margin: 0 0 5px; font-size: 15px; }
.bgp-faq p { margin: 0; color: var(--text-2); line-height: 1.6; font-size: 14px; }
.bgp-related { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.bgp-related a { color: #0f766e; font-weight: 600; }
.bgp-others-nav { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-top: 18px; padding: 14px 0 4px; font-size: 13.5px; color: var(--text-2); }
.bgp-others-nav a { color: #0f766e; font-weight: 600; }
.bgp-hub-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.bgp-hub-card { display: flex; flex-direction: column; gap: 4px; padding: 16px; border: 1px solid var(--border, #e5e7eb); border-radius: 14px; text-decoration: none; transition: border-color .15s, box-shadow .15s, transform .15s; }
.bgp-hub-card:hover { border-color: #14b8a6; box-shadow: 0 6px 18px rgba(15,118,110,.12); transform: translateY(-2px); }
.bgp-hub-card strong { font-size: 15.5px; color: var(--ink, #0f172a); }
.bgp-hub-card em { font-style: normal; font-size: 13.5px; color: #0f766e; font-weight: 700; }
.bgp-hub-go { margin-top: 6px; font-size: 12.5px; color: var(--text-2); }
@media ( max-width: 600px ) {
	.bgp-table { min-width: 0; font-size: 13px; }
	.bgp-table thead { display: none; }
	.bgp-table tbody tr { display: block; border: 1px solid var(--border, #e5e7eb); border-radius: 12px; margin-bottom: 10px; padding: 4px 0; }
	.bgp-table tbody td { display: flex; justify-content: space-between; gap: 16px; text-align: right; border: none; padding: 7px 14px; white-space: normal; }
	.bgp-table tbody td::before { content: attr(data-th); font-weight: 600; color: var(--text-2); text-align: left; }
	.bgp-table tbody td:first-child { background: #f0fbfa; font-size: 14px; }
	.bgp-table tbody td:first-child::before { content: ""; }
}

/* ===== Check hợp đồng — Dashboard Mobile-First ===== */
.hd { display: flex; flex-direction: column; gap: 14px; }
.hd-hero { border-radius: 18px; padding: 22px 20px; color: #fff; display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.hd-hero.tone-good { background: linear-gradient(135deg, #0f766e, #16a34a); }
.hd-hero.tone-warn { background: linear-gradient(135deg, #d97706, #f59e0b); }
.hd-hero.tone-risk { background: linear-gradient(135deg, #dc2626, #ef4444); }
.hd-score { display: flex; align-items: baseline; gap: 2px; line-height: 1; }
.hd-score-num { font-size: 64px; font-weight: 800; letter-spacing: -1px; }
.hd-score-max { font-size: 22px; font-weight: 700; opacity: .85; }
.hd-hero-meta { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.hd-rating, .hd-verdict-pill { display: inline-flex; align-items: center; gap: 6px; padding: 7px 15px; border-radius: 999px; font-size: 13.5px; font-weight: 700; }
.hd-rating { background: rgba(255,255,255,.2); color: #fff; }
.hd-rating .icon { width: 16px; height: 16px; }
.hd-verdict-pill { background: #fff; }
.hd-verdict-pill.tone-good { color: #15803d; }
.hd-verdict-pill.tone-warn { color: #b45309; }
.hd-verdict-pill.tone-risk { color: #b91c1c; }
.hd-summary p { margin: 0; color: var(--text-2); line-height: 1.65; }

.hd-scores { display: flex; flex-direction: column; gap: 13px; }
.hd-score-top { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; margin-bottom: 5px; gap: 10px; }
.hd-score-top strong small { font-weight: 600; color: var(--text-2); }
.hd-bar { height: 8px; border-radius: 99px; background: #eef2f7; overflow: hidden; }
.hd-bar span { display: block; height: 100%; border-radius: 99px; transition: width .4s ease; }
.hd-score-row.tone-good .hd-bar span { background: #16a34a; }
.hd-score-row.tone-warn .hd-bar span { background: #f59e0b; }
.hd-score-row.tone-risk .hd-bar span { background: #ef4444; }

.hd-danger-list { display: flex; flex-direction: column; gap: 12px; }
.hd-danger { border: 1px solid var(--border, #e5e7eb); border-left-width: 4px; border-radius: 12px; padding: 14px; }
.hd-danger.tone-risk { border-left-color: #ef4444; background: #fef2f2; }
.hd-danger.tone-warn { border-left-color: #f59e0b; background: #fffbeb; }
.hd-danger.tone-good { border-left-color: #16a34a; background: #ecfdf5; }
.hd-level { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 3px 10px; border-radius: 99px; margin-bottom: 8px; }
.hd-level.tone-risk { background: #fee2e2; color: #b91c1c; }
.hd-level.tone-warn { background: #fef3c7; color: #b45309; }
.hd-level.tone-good { background: #dcfce7; color: #15803d; }
.hd-clause { margin: 0 0 10px; padding: 9px 12px; background: rgba(15,23,42,.05); border-radius: 8px; font-style: italic; font-size: 13.5px; color: #334155; line-height: 1.5; }
.hd-danger-detail { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; line-height: 1.55; }
.hd-danger-detail b { color: #0f172a; }
.hd-fix { color: #15803d; }
.hd-fix .icon { width: 15px; height: 15px; vertical-align: -3px; }

.hd-ps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.hd-ps li { display: flex; gap: 12px; align-items: flex-start; }
.hd-ps-rate { flex: 0 0 auto; min-width: 66px; text-align: center; padding: 6px 8px; border-radius: 8px; font-size: 12.5px; font-weight: 800; }
.hd-ps li.tone-risk .hd-ps-rate { background: #fee2e2; color: #b91c1c; }
.hd-ps li.tone-warn .hd-ps-rate { background: #fef3c7; color: #b45309; }
.hd-ps li.tone-good .hd-ps-rate { background: #dcfce7; color: #15803d; }
.hd-ps-body { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.hd-ps-body em { font-style: normal; color: var(--text-2); font-size: 13px; }

.hd-verdict-card { border-left: 4px solid #f59e0b; }
.hd-verdict-card.tone-good { border-left-color: #16a34a; }
.hd-verdict-card.tone-warn { border-left-color: #f59e0b; }
.hd-verdict-card.tone-risk { border-left-color: #ef4444; }
.hd-verdict-big { font-size: 22px; font-weight: 800; margin: 2px 0 8px; }
.hd-verdict-big.tone-good { color: #15803d; }
.hd-verdict-big.tone-warn { color: #b45309; }
.hd-verdict-big.tone-risk { color: #b91c1c; }
.hd-verdict-card p { margin: 0; color: var(--text-2); line-height: 1.65; }

@media ( min-width: 640px ) {
	.hd-hero { flex-direction: row; justify-content: center; gap: 26px; }
	.hd-hero-meta { justify-content: flex-start; }
	.hd-score-num { font-size: 76px; }
}

/* ===== Cổng "Tạo hồ sơ" mở khoá báo cáo đầy đủ ===== */
.cn-gated[hidden] { display: none; }
.cn-gated.cn-locked { filter: blur(7px); pointer-events: none; user-select: none; opacity: .92; max-height: 340px; overflow: hidden; -webkit-mask-image: linear-gradient( #000 48%, transparent ); mask-image: linear-gradient( #000 48%, transparent ); }
.market-cta.is-locked { border-color: #99e0d7; }
.cn-reg-form { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.cn-reg-title { margin: 0 0 2px; font-size: 14px; font-weight: 700; color: #0f172a; line-height: 1.4; }
.cn-reg-form input { height: 46px; border: 1px solid var(--border-2, #d1d5db); border-radius: 11px; padding: 0 14px; font-size: 15px; background: #fff; }
.cn-reg-form input:focus { border-color: #0f766e; outline: none; box-shadow: 0 0 0 3px rgba(15,118,110,.12); }
.cn-reg-form .btn-block { width: 100%; justify-content: center; height: 48px; font-size: 15px; }
.cn-reg-note { margin: 0; font-size: 12.5px; color: var(--text-2); line-height: 1.5; }
.cn-reg-msg { margin: 0; font-size: 13px; color: var(--text-2); }
.cn-reg-msg:empty { display: none; }
.cn-reg-msg.is-err { color: #dc2626; font-weight: 600; }

/* ===== Đợt 1: phễu SĐT/Zalo — teaser, cam kết bảo mật, CTA chuyển đơn ===== */
/* Teaser: tín hiệu nhử xuất hiện lần lượt */
.tz-card { border: 1px solid #fde68a; background: linear-gradient(135deg, #fffbeb, #fff7ed); }
.tz-count { font-weight: 700; font-size: 15px; margin-bottom: 10px; color: #92400e; display: flex; align-items: center; gap: 8px; }
.tz-count-n { display: inline-grid; place-items: center; min-width: 30px; height: 30px; padding: 0 8px; border-radius: 999px; background: #dc2626; color: #fff; font-size: 16px; }
.tz-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.tz-signal { display: flex; align-items: flex-start; gap: 10px; padding: 11px 12px; border-radius: 12px; background: #fff; border: 1px solid #fde0a3; font-size: 13.5px; line-height: 1.5; opacity: 0; transform: translateY(8px); animation: tzIn .45s ease forwards; }
.tz-signal-ic { flex: 0 0 auto; color: #d97706; display: grid; place-items: center; }
.tz-signal-ic .icon { width: 18px; height: 18px; }
.tz-more { background: #fff7ed; border-color: #fdba74; color: #9a3412; font-weight: 700; font-style: normal; }
.tz-more strong { color: #c2410c; }
.tz-more .tz-signal-ic { color: #ea580c; }
@keyframes tzIn { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .tz-signal { animation: none; opacity: 1; transform: none; } }

/* Cổng SĐT/Zalo: dòng phụ + cam kết bảo mật */
.report-gate-sub { margin: 8px 0 0; font-size: 12.5px; color: var(--text-2); text-align: center; }
.report-secure { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; padding: 12px; border-radius: 12px; background: #f0fdfa; border: 1px solid #99f6e4; text-align: left; }
.report-secure > div { flex: 1; min-width: 0; text-align: left; }
.report-secure-ic { flex: 0 0 auto; color: #0f766e; }
.report-secure-ic .icon { width: 22px; height: 22px; }
.report-secure b { display: block; font-size: 13px; }
.report-secure ul { margin: 5px 0 0; padding-left: 18px; font-size: 12.5px; color: var(--text-2); line-height: 1.6; list-style: disc; text-align: left; }
.report-secure li { text-align: left; }

/* CTA chuyển đơn về CheckNha (cuối báo cáo) */
.cta-switch { border: 1px solid #a7e0d8; background: linear-gradient(135deg, #ecfdf5, #f0fbfa); }
.cta-switch-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.cta-switch-ic { width: 46px; height: 46px; border-radius: 12px; flex: 0 0 auto; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #0f766e, #14b8a6); }
.cta-switch-ic .icon { width: 24px; height: 24px; }
.cta-switch-head h3 { margin: 0; font-size: 16px; line-height: 1.35; }
.cta-switch-head p { margin: 5px 0 0; font-size: 13.5px; color: var(--text-2); line-height: 1.55; }
.cta-switch-btn { justify-content: center; }
.cta-switch-note { margin: 8px 0 0; font-size: 12px; color: var(--text-2); text-align: center; }
.cta-switch-msg { margin: 8px 0 0; font-size: 13px; font-weight: 600; text-align: center; }
.cta-switch-msg:empty { display: none; }
.cta-switch-msg.is-ok { color: #15803d; }
.cta-switch-msg.is-err { color: #dc2626; }

/* ============ Công cụ Chuyển đổi báo giá ============ */
.conv-wrap { max-width: 1100px; }
.conv-upload { border: 2px dashed var(--border-2, #cbd5e1); border-radius: 16px; padding: 28px 20px; text-align: center; background: var(--surface, #fff); cursor: pointer; transition: border-color .15s, background .15s; }
.conv-upload.is-over { border-color: var(--brand, #16a34a); background: #f0fdf4; }
.conv-drop-ic { font-size: 34px; }
.conv-drop-h { margin: 8px 0 4px; font-size: 15px; }
.conv-browse { border: none; background: none; color: var(--brand, #16a34a); font-weight: 700; cursor: pointer; text-decoration: underline; font-size: 15px; }
.conv-drop-sub { margin: 0; font-size: 12.5px; color: var(--text-2, #64748b); }
.conv-file { margin: 10px 0 0; font-size: 13px; font-weight: 600; color: var(--text-1, #0f172a); }
.conv-actions-top { display: flex; align-items: center; gap: 14px; margin: 14px 0; flex-wrap: wrap; }
.conv-status { font-size: 13px; color: var(--text-2, #475569); }

.conv-card { background: var(--surface, #fff); border: 1px solid var(--border-2, #e2e8f0); border-radius: 14px; padding: 16px; margin: 0 0 14px; box-shadow: var(--shadow, 0 1px 3px rgba(0,0,0,.06)); }
.conv-card h3 { margin: 0 0 12px; font-size: 15px; }
.conv-cust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.conv-f { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 600; color: var(--text-2, #475569); }
.conv-f-wide { grid-column: 1 / -1; }
.conv-f input { padding: 8px 10px; border: 1px solid var(--border-2, #cbd5e1); border-radius: 8px; font-size: 13.5px; font-weight: 500; color: var(--text, #0f172a); }
.conv-f input:focus { outline: none; border-color: var(--brand, #16a34a); }

.conv-warns { background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px; padding: 10px 14px; margin: 0 0 14px; }
.conv-warns p { margin: 2px 0; font-size: 12.5px; color: #92400e; }

.conv-group-head { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; }
.conv-group-name { flex: 1 1 auto; font-size: 14.5px; font-weight: 700; padding: 7px 10px; border: 1px solid var(--border-2, #cbd5e1); border-radius: 8px; background: #f8fafc; }
.conv-del-group { flex: 0 0 auto; font-size: 12px; color: #b91c1c; background: none; border: 1px solid #fecaca; border-radius: 8px; padding: 6px 10px; cursor: pointer; }
.conv-tablewrap { overflow-x: auto; }
.conv-table { width: 100%; border-collapse: collapse; min-width: 1040px; table-layout: fixed; }
.conv-table th { background: #f1f5f9; font-size: 11.5px; text-transform: uppercase; letter-spacing: .2px; color: #475569; padding: 7px 6px; text-align: left; border: 1px solid #e2e8f0; white-space: nowrap; }
.conv-table td { border: 1px solid #e2e8f0; padding: 2px; vertical-align: top; }
.conv-table .conv-stt { text-align: center; font-size: 12px; color: #94a3b8; padding: 6px; }
.conv-table input, .conv-table textarea { width: 100%; border: none; padding: 7px 6px; font-size: 13px; background: transparent; color: var(--text, #0f172a); font-family: inherit; }
.conv-table input:focus, .conv-table textarea:focus { outline: 2px solid var(--brand, #16a34a); outline-offset: -2px; border-radius: 4px; background: #fff; }
/* Ô chữ tự xuống dòng, hiện đủ nội dung */
.conv-ta { resize: none; overflow: hidden; line-height: 1.4; white-space: pre-wrap; word-break: break-word; min-height: 32px; display: block; }
/* Bề rộng từng cột (table-layout fixed) */
.conv-table col.cw-stt { width: 36px; }
.conv-table col.cw-hm { width: 16%; }
.conv-table col.cw-mt { width: 12%; }
.conv-table col.cw-vl { width: 23%; }
.conv-table col.cw-dvt { width: 50px; }
.conv-table col.cw-kl { width: 62px; }
.conv-table col.cw-dg { width: 94px; }
.conv-table col.cw-tt { width: 108px; }
.conv-table col.cw-gc { width: 12%; }
.conv-table col.cw-del { width: 32px; }
.conv-c-num input, .conv-c-num { text-align: right; }
.conv-c-money input { font-variant-numeric: tabular-nums; letter-spacing: .2px; }
.conv-c-tt input { font-weight: 700; color: #0f172a; }
.conv-c-sm input { text-align: center; }
.conv-table tr.has-flag td { background: #fff7ed; }
.conv-flags { display: flex; flex-wrap: wrap; gap: 3px; padding: 4px 6px 0; }
.conv-flag { font-size: 10.5px; font-weight: 700; color: #b45309; background: #fef3c7; border: 1px solid #fde68a; border-radius: 6px; padding: 1px 6px; }
.conv-del-row { border: none; background: none; color: #ef4444; cursor: pointer; font-size: 14px; padding: 6px 8px; }
.conv-add-row { margin-top: 8px; font-size: 13px; font-weight: 600; color: var(--brand, #16a34a); background: none; border: 1px dashed #bbf7d0; border-radius: 8px; padding: 7px 12px; cursor: pointer; }
.conv-add-group { display: block; width: 100%; margin: 0 0 16px; font-size: 13.5px; font-weight: 700; color: var(--brand, #16a34a); background: #f0fdf4; border: 1px dashed #86efac; border-radius: 10px; padding: 11px; cursor: pointer; }

.conv-totals { display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between; }
.conv-tot-opts { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; font-size: 13px; color: var(--text-1, #334155); }
.conv-tot-opts input[type="number"] { padding: 6px 8px; border: 1px solid var(--border-2, #cbd5e1); border-radius: 7px; }
.conv-mini { width: 56px; } .conv-mini2 { width: 110px; }
.conv-inline { display: inline-flex; align-items: center; gap: 6px; }
.conv-tot-rows { min-width: 240px; margin-left: auto; }
.conv-tr { display: flex; justify-content: space-between; gap: 24px; padding: 4px 0; font-size: 13.5px; color: var(--text-1, #334155); }
.conv-grand { border-top: 2px solid #e2e8f0; margin-top: 6px; padding-top: 8px; font-size: 16px; font-weight: 800; color: var(--brand, #16a34a); }
.conv-export { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 24px; }
.conv-btn2 { font-size: 14px; font-weight: 700; padding: 11px 18px; border-radius: 10px; border: 1.5px solid var(--border-2, #cbd5e1); background: #fff; color: var(--text-1, #334155); cursor: pointer; }
.conv-btn2:hover { border-color: var(--brand, #16a34a); color: var(--brand, #16a34a); }
.conv-btn-zalo { font-size: 14px; font-weight: 800; padding: 11px 18px; border-radius: 10px; border: none; cursor: pointer; color: #fff; background: linear-gradient(135deg, #0068ff 0%, #00a3ff 100%); box-shadow: 0 6px 16px rgba(0,104,255,.3); }
.conv-btn-zalo:hover { box-shadow: 0 10px 22px rgba(0,104,255,.42); }
/* Nút xuất báo giá khuôn thương hiệu BALI.HOME (navy + vàng đồng) */
.conv-btn-bali { font-size: 14px; font-weight: 800; padding: 11px 18px; border-radius: 10px; cursor: pointer; color: #E9C87A; background: linear-gradient(135deg, #1B2A4A 0%, #24385f 100%); border: 1.5px solid #C5A253; letter-spacing: .02em; box-shadow: 0 6px 16px rgba(27,42,74,.35); }
.conv-btn-bali:hover { box-shadow: 0 10px 22px rgba(27,42,74,.5); color: #fff; }
@media (max-width: 640px) { .conv-cust { grid-template-columns: 1fr 1fr; } }

/* =========================================================
   P1 — Footer, khối bảo mật, báo cáo mẫu, trang nội dung
   ========================================================= */

/* --- Footer toàn site --- */
.site-footer { margin-top: 40px; border-top: 1px solid var(--border-2); background: var(--surface); }
.sf-inner { max-width: 1400px; margin: 0 auto; padding: 36px 32px 8px; display: grid; grid-template-columns: 1.4fr 2fr; gap: 32px; }
.sf-logo { height: 40px; width: auto; margin-bottom: 12px; }
.sf-desc { font-size: 13.5px; color: var(--text-2); margin: 0 0 14px; max-width: 340px; line-height: 1.6; }
.sf-contact { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.sf-contact li { font-size: 13.5px; color: var(--text-2); }
.sf-contact a { color: var(--brand); font-weight: 600; }
.sf-ic { margin-right: 4px; }
.sf-legal { font-size: 12.5px; color: var(--text-3); margin: 0; }
.sf-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.sf-col h4 { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--text); margin: 0 0 12px; }
.sf-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.sf-col a { font-size: 13.5px; color: var(--text-2); text-decoration: none; }
.sf-col a:hover { color: var(--brand); }
.sf-bottom { max-width: 1400px; margin: 0 auto; padding: 16px 32px 28px; border-top: 1px solid var(--border); font-size: 12.5px; color: var(--text-3); }
@media (max-width: 860px) {
	.sf-inner { grid-template-columns: 1fr; gap: 24px; padding: 28px 16px 8px; }
	.sf-bottom { padding: 16px 16px 24px; }
}
@media (max-width: 520px) { .sf-cols { grid-template-columns: 1fr 1fr; gap: 18px; } }

/* --- Khối cam kết bảo mật ở ô upload --- */
.upload-secure { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 0; padding: 12px 14px; border: 1px solid var(--brand-bg); background: var(--brand-bg); border-radius: 12px; }
.upload-secure-ic { flex: 0 0 auto; font-size: 18px; line-height: 1.3; }
.upload-secure p { margin: 0; font-size: 12.5px; color: #245b54; line-height: 1.6; }
.upload-secure a { color: var(--brand); font-weight: 700; white-space: nowrap; }

/* --- Băng "Xem báo cáo mẫu" trang chủ --- */
.sample-band { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--border-2); border-radius: var(--radius); padding: 20px 24px; box-shadow: var(--shadow); margin-bottom: 24px; }
.sample-band-text h2 { font-size: 17px; margin: 0 0 4px; }
.sample-band-text p { font-size: 13.5px; color: var(--text-2); margin: 0; max-width: 640px; line-height: 1.6; }
.cn-sample-btn { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.cn-sample-btn .icon { width: 16px; height: 16px; }
.check-sample-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 16px; font-size: 13.5px; color: var(--text-2); }

/* --- Modal báo cáo mẫu --- */
.cn-sample-overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(2,6,23,.55); display: flex; align-items: flex-start; justify-content: center; padding: 24px 14px; overflow-y: auto; }
.cn-sample-overlay[hidden] { display: none; }
.cn-sample-box { position: relative; width: 100%; max-width: 640px; background: var(--surface); border-radius: 18px; padding: 22px; box-shadow: 0 24px 70px rgba(2,6,23,.4); animation: dk-pop .22s ease; }
.cn-sample-x { position: absolute; top: 10px; right: 12px; width: 34px; height: 34px; border: none; background: var(--border); border-radius: 50%; font-size: 20px; line-height: 1; color: var(--text-2); cursor: pointer; }
.cn-sample-x:hover { background: var(--border-2); }

/* --- Nội dung báo cáo mẫu --- */
.sr-report { font-size: 14px; }
.sr-badge { display: inline-block; font-size: 12px; font-weight: 700; color: var(--amber); background: var(--amber-bg); border-radius: 999px; padding: 5px 12px; margin-bottom: 14px; }
.sr-hero { display: flex; gap: 16px; align-items: center; padding: 14px; border-radius: 14px; background: var(--brand-bg); margin-bottom: 18px; }
.sr-score { flex: 0 0 auto; }
.sr-score-num { font-size: 34px; font-weight: 800; color: var(--brand); }
.sr-score-max { font-size: 16px; color: var(--text-2); }
.sr-hero-text h3 { margin: 0 0 4px; font-size: 16px; }
.sr-hero-text p { margin: 0; font-size: 13px; color: var(--text-2); }
.sr-h { font-size: 14px; font-weight: 800; margin: 18px 0 8px; }
.sr-table-wrap { overflow-x: auto; }
.sr-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.sr-table th { text-align: left; padding: 8px 10px; background: var(--bg); color: var(--text-2); font-weight: 700; border-bottom: 1px solid var(--border-2); }
.sr-table td { padding: 9px 10px; border-bottom: 1px solid var(--border); vertical-align: top; }
.sr-diff { font-weight: 700; white-space: nowrap; }
.sr-warn { color: #b45309; }
.sr-good { color: #15803d; }
.sr-mini { font-size: 11.5px; color: var(--text-3); margin: 6px 0 0; }
.sr-flags, .sr-ask { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 7px; }
.sr-flags li, .sr-ask li { font-size: 13px; color: var(--text); line-height: 1.55; }
.sr-ask li { color: var(--text-2); font-style: italic; }
.sr-cta { margin-top: 20px; text-align: center; }
@media (max-width: 560px) {
	.sr-table thead { display: none; }
	.sr-table, .sr-table tbody, .sr-table tr, .sr-table td { display: block; width: 100%; }
	.sr-table tr { border: 1px solid var(--border-2); border-radius: 10px; margin-bottom: 10px; padding: 4px 2px; }
	.sr-table td { border: none; padding: 5px 10px; }
	.sr-table td::before { content: attr(data-th) ": "; font-weight: 700; color: var(--text-2); }
	.sr-table td:first-child::before { content: ""; }
	.sr-table td:first-child { font-weight: 700; }
}

/* --- Trang nội dung (giới thiệu / chính sách / điều khoản) --- */
.content-page { max-width: 820px; }
.cp-updated { font-size: 12.5px; color: var(--text-3); margin: 0 0 14px; }
.cp-card { background: var(--surface); border: 1px solid var(--border-2); border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow); margin-bottom: 16px; }
.cp-card h2 { font-size: 17px; margin: 0 0 10px; }
.cp-card p { font-size: 14px; color: var(--text); line-height: 1.7; margin: 0 0 10px; }
.cp-card p:last-child { margin-bottom: 0; }
.cp-lead p { font-size: 15px; }
.cp-note { font-size: 13px; color: var(--text-2); background: var(--bg); border-radius: 10px; padding: 10px 12px; }
.cp-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }
.cp-list li { font-size: 14px; color: var(--text); line-height: 1.6; }
.cp-commit { border-color: var(--brand); background: var(--brand-bg); }
.cp-contact-list { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.cp-contact-list a { color: var(--brand); font-weight: 600; }

/* =========================================================
   P2 — Cảm nhận khách hàng + tinh chỉnh mobile
   ========================================================= */

/* --- Cảm nhận khách hàng --- */
.testi-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.testi-card { background: var(--bg); border: 1px solid var(--border-2); border-radius: 14px; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.testi-stars { color: #f59e0b; font-size: 14px; letter-spacing: 1px; }
.testi-card blockquote { margin: 0; font-size: 14px; color: var(--text); line-height: 1.65; flex: 1 1 auto; }
.testi-card figcaption { display: flex; flex-direction: column; gap: 2px; }
.testi-name { font-weight: 800; font-size: 13.5px; color: var(--text); }
.testi-area { font-size: 12.5px; color: var(--text-3); }
@media (max-width: 900px) { .testi-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .testi-grid { grid-template-columns: 1fr; gap: 12px; } }

/* --- Tinh chỉnh mobile (P2) --- */
@media (max-width: 560px) {
	/* Băng "Xem báo cáo mẫu": xếp dọc, nút chiếm full chiều ngang cho dễ chạm */
	.sample-band { flex-direction: column; align-items: stretch; gap: 14px; padding: 16px; }
	.sample-band .cn-sample-btn { width: 100%; justify-content: center; }
	.check-sample-row { justify-content: space-between; }
	.check-sample-row .cn-sample-btn { flex: 0 0 auto; }
	/* Modal báo cáo mẫu: sát mép cho rộng */
	.cn-sample-box { padding: 16px; border-radius: 14px; }
}
/* Vùng chạm tối thiểu 44px trên cảm ứng cho nút & mục menu (chuẩn mobile) */
@media (hover: none) and (pointer: coarse) {
	.nav-item { min-height: 44px; }
	.btn-ghost, .btn-soft, .cn-sample-btn, .hero-cta-btn, .dropzone-analyze, .cta3d-btn { min-height: 44px; }
	.sf-col a, .sf-contact a { display: inline-block; padding: 3px 0; }
}

/* --- Chat mời tư vấn (proactive, tự bật) --- */
.cn-nudge { position: fixed; left: 20px; bottom: 20px; z-index: 990; width: 300px; max-width: calc(100vw - 40px); background: var(--surface); border: 1px solid var(--border-2); border-radius: 16px; box-shadow: 0 16px 44px rgba(2,6,23,.22); padding: 16px 16px 14px; transform: translateY(16px); opacity: 0; transition: transform .26s ease, opacity .26s ease; }
.cn-nudge.is-in { transform: translateY(0); opacity: 1; }
.cn-nudge[hidden] { display: none; }
.cn-nudge-x { position: absolute; top: 8px; right: 10px; border: none; background: transparent; font-size: 20px; line-height: 1; color: var(--text-3); cursor: pointer; }
.cn-nudge-x:hover { color: var(--text); }
.cn-nudge-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.cn-nudge-av { width: 38px; height: 38px; border-radius: 50%; background: var(--brand-bg); display: grid; place-items: center; font-size: 20px; flex: 0 0 auto; }
.cn-nudge-id b { display: block; font-size: 14px; color: var(--text); }
.cn-nudge-id em { font-style: normal; font-size: 12px; color: #16a34a; display: flex; align-items: center; gap: 5px; }
.cn-nudge-dot { width: 7px; height: 7px; border-radius: 50%; background: #16a34a; display: inline-block; animation: cn-nudge-pulse 1.8s infinite; }
@keyframes cn-nudge-pulse { 0%{box-shadow:0 0 0 0 rgba(22,163,74,.5)} 70%{box-shadow:0 0 0 6px rgba(22,163,74,0)} 100%{box-shadow:0 0 0 0 rgba(22,163,74,0)} }
.cn-nudge-msg { font-size: 13px; color: var(--text); line-height: 1.6; margin: 0 0 12px; }
.cn-nudge-go { display: block; width: 100%; border: none; cursor: pointer; font-family: inherit; font-weight: 800; font-size: 14px; color: #fff; padding: 12px; border-radius: 12px; background: linear-gradient(135deg,#22c55e,var(--green)); box-shadow: 0 8px 18px rgba(22,163,74,.32); }
.cn-nudge-go:hover { filter: brightness(1.03); }
.cn-nudge-foot { font-size: 11px; color: var(--text-3); text-align: center; margin: 8px 0 0; }
/* Mobile: bám mép trái. Đã ẩn widget chat plugin (hcai) trên mobile nên popup rộng thoải mái. */
@media (max-width: 560px) { .cn-nudge { left: 12px; right: 12px; bottom: 14px; width: auto; max-width: none; } }
@media (prefers-reduced-motion: reduce) { .cn-nudge { transition: opacity .2s; } .cn-nudge-dot { animation: none; } }

/* Ẩn khung chat plugin AIChatWeb (namespace .hcai-* / #hcai-*) TRÊN MOBILE — tránh chồng lên
   popup "Trợ lý CheckNha". Desktop vẫn giữ nguyên khung chat AI. */
@media (max-width: 640px) {
	[class^="hcai-"], [class*=" hcai-"], [id^="hcai-"] { display: none !important; }
}
