/* Bộ nhận diện OneCAD Việt Nam cho trang bản quyền (mockup «Bản quyền OneCAD» anh Tâm duyệt 27/10/2026).
   Nạp SAU app.css: đổi token + kiểu nút / thẻ / bảng; bố cục đầu trang, Tổng quan, chi tiết doanh nghiệp ở cuối tệp.
   Trắng / đen là chủ đạo, màu thương hiệu chỉ cho liên kết và điểm nhấn; góc gần vuông (4px nút, 6px thẻ); thẻ viền mảnh, không đổ bóng. */
:root {
  --brand: #0b0d10; --brand-2: #2a2f37; --link: #0061ae; --link-2: #0051a1;
  --ink: #0b0d10; --text: #0b0d10; --muted: #4b5260; --faint: #7a8291;
  --line: #e1e5ea; --line-2: #eef1f5; --bg: #f4f6f8; --panel: #fff; --hover: #f7f8fa;
  --ok: #297a2d; --ok-bg: #eaf4e3; --warn: #8a5300; --warn-bg: #fff3dc; --bad: #b42318; --bad-bg: #fdecea; --off: #4b5260; --off-bg: #eef1f5;
  --teal: #107072; --green: #297a2d; --r: 6px; --shadow: none; --shadow-lg: 0 18px 40px -18px rgba(0,0,0,.35);
  font-family: "Be Vietnam Pro", system-ui, -apple-system, "Segoe UI", sans-serif;
}
body { font-size: 15px; line-height: 1.6; background: var(--bg); }
a { color: var(--link); } a:hover { color: var(--link-2); }
em { color: inherit; }

/* Đầu trang: chữ OneCAD + menu mục, gạch chân đen mục đang mở */
.top { position: sticky; top: 0; height: auto; padding: 0; background: #fff; backdrop-filter: none; border-bottom: 1px solid var(--line); display: block; }
.topin { max-width: 1360px; margin: 0 auto; padding: 0 40px; min-height: 64px; display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
.wm { display: inline-flex; align-items: center; gap: 4px; text-decoration: none; white-space: nowrap; padding: 4px 0; }
.wm img { display: block; width: 120px; height: auto; }
.wm .g { color: #297a2d; } .wm .b { color: #0061ae; } .wm .t { color: var(--muted); font-weight: 500; font-size: 15px; margin-left: 10px; letter-spacing: 0; }
.mainnav { display: flex; gap: 2px; flex-wrap: wrap; align-self: stretch; }
.mainnav a, .mainnav button { display: inline-flex; align-items: center; gap: 6px; padding: 0 14px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--muted); font: inherit; font-size: 15px; text-decoration: none; cursor: pointer; min-height: 62px; }
.mainnav a:hover, .mainnav button:hover { color: var(--ink); }
.mainnav .on { color: var(--ink); font-weight: 600; border-bottom-color: var(--ink); }
.mainnav em { color: var(--faint); font-weight: 500; font-size: 13px; }
.me .av { border-radius: 999px; width: 34px; height: 34px; }
.me div b { font-weight: 600; font-size: 14px; }
.ghost { color: var(--muted); border-radius: 4px; }

/* Khung trang + tiêu đề */
.wrap { max-width: 1360px; padding: 36px 40px 56px; }
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 1.5px; color: var(--muted); text-transform: uppercase; }
.head { margin-bottom: 18px; flex-wrap: wrap; }
.head h1 { font-size: 40px; line-height: 44px; font-weight: 800; letter-spacing: -1.4px; margin-top: 8px; text-wrap: balance; }
.head .sub { color: var(--muted); margin-top: 6px; max-width: 680px; }
.prods { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 22px; }
.prods a, .prods button { display: inline-flex; align-items: center; height: 36px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); font: inherit; font-size: 14px; text-decoration: none; cursor: pointer; }
.prods .on { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 600; }
.crumbs { font-size: 13.5px; color: var(--muted); margin-bottom: 14px; } .crumbs a { text-decoration: none; }

/* Nút: chính = nền đen; phụ = viền đen 1.5px; góc 4px; không bóng */
.btn { height: 44px; padding: 0 18px; border-radius: 4px; border: 1.5px solid var(--ink); background: #fff; color: var(--ink); font-weight: 600; font-size: 14px; box-shadow: none; }
.btn:hover { background: var(--hover); }
.btn.primary { background: var(--ink); border-color: var(--ink); color: #fff; box-shadow: none; }
.btn.primary:hover { background: var(--brand-2); }
.btn.danger { background: var(--bad); border-color: var(--bad); }
.btn.navy { background: var(--ink); border-color: var(--ink); }
.btn.sm { height: 36px; padding: 0 12px; font-size: 13px; }
.iconbtn { border-radius: 4px; }

/* Ô số liệu */
.stats, .stats.co { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stats:not(.co) { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.stat { border-radius: 6px; box-shadow: none; padding: 20px 22px; }
.stat:hover { transform: none; }
.stat .ic { display: none; }
.stat span { order: -1; color: var(--muted); font-size: 13px; margin: 0; }
.stat b { font-size: 34px; font-weight: 800; letter-spacing: -1px; margin-top: 6px; color: var(--c, var(--ink)); }
.stat small { color: var(--muted); font-size: 13px; margin-top: 2px; }
.stat { display: flex; flex-direction: column; }

/* Thẻ + bảng */
.card { border-radius: 6px; box-shadow: none; }
.bar { padding: 16px 22px; }
.search { border-radius: 4px; height: 40px; }
.search:focus-within { border-color: var(--ink); box-shadow: none; }
.grid th { background: none; font-size: 12px; font-weight: 700; letter-spacing: 1px; color: var(--muted); padding: 12px 22px; }
.grid td { padding: 14px 22px; border-bottom: 1px solid var(--line); font-size: 14px; }
.grid tbody tr.sel { background: #f4f8ff; }
.av { border-radius: 999px; }
.who b { font-weight: 600; }
.pill { font-size: 12.5px; padding: 3px 10px; }
.pill::before { display: none; }
.code { border-radius: 4px; }
.seg, .seg button { border-radius: 4px; }
.sort select, .sel { border-radius: 4px; }
.foot { color: var(--muted); font-size: 13px; }
.tabs { display: none; }

/* Hộp thoại, ô nhập, ngăn chi tiết */
.dialog { border-radius: 8px; }
.f input, .addm input, .keybox { border-radius: 4px; }
.f input:focus, .addm input:focus { border-color: var(--ink); box-shadow: none; }
.f > span b { color: var(--bad); }
.pills button { border-radius: 4px; }
.pills button.on { border-color: var(--ink); background: var(--ink); color: #fff; }
.danger-zone { border-radius: 6px; }
.mlist, .actcode code { border-radius: 4px; }
.rolechoice { border-radius: 4px; } .rolechoice:has(input:checked) { border-color: var(--ink); background: var(--hover); }
.toast { border-radius: 6px; }
.tag { border-radius: 4px; background: var(--off-bg); color: var(--muted); }

/* ---- Tổng quan (gộp mọi sản phẩm) ---- */
.ov { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; margin-top: 24px; }
.ov > .card:first-child { flex: 999 1 640px; min-width: 0; }
.ov > aside { flex: 1 1 340px; min-width: 0; }
.cardh { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.cardh h2 { margin: 0; font-size: 20px; font-weight: 700; color: var(--ink); }
.cardh small { color: var(--muted); font-size: 13px; }
.cardf { margin: 0; padding: 14px 22px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.lst { list-style: none; margin: 0; padding: 0; }
.lst li { display: flex; gap: 10px; align-items: center; padding: 14px 22px; border-bottom: 1px solid var(--line); }
.lst li:last-child { border-bottom: 0; }
.lst li > div { flex: 1; min-width: 0; }
.lst b { display: block; font-weight: 600; overflow-wrap: anywhere; }
.lst small { color: var(--muted); font-size: 12.5px; }
.prodtag { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .5px; color: var(--teal); }
.login-need { padding: 18px 22px; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; border-bottom: 1px solid var(--line); background: var(--hover); font-size: 14px; }

/* ---- Chi tiết doanh nghiệp (trang riêng, thay ngăn kéo) ---- */
.dt-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 6px 0 22px; }
.dt-card { background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 20px 22px; display: flex; flex-direction: column; gap: 6px; }
.dt-card > span { color: var(--muted); font-size: 13px; }
.dt-card > b { font-size: 28px; font-weight: 800; letter-spacing: -.8px; color: var(--c, var(--ink)); line-height: 1.2; }
.dt-card > small { color: var(--muted); font-size: 13px; }
.dt-card .meter { height: 6px; margin: 4px 0; }
.dt-two { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; margin-top: 22px; }
.dt-two .card { padding: 4px 22px 8px; }
.dt-two .sec:last-child { border-bottom: 0; }
tr.attn { background: #fff8f7; }
@media (max-width: 1100px) { .stats:not(.co) { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px) { .dt-cards, .dt-two { grid-template-columns: 1fr; } }
@media (max-width: 760px) {
  .topin { padding: 0 16px; gap: 10px; } .mainnav a, .mainnav button { min-height: 44px; padding: 0 10px; }
  .wrap { padding: 22px 16px 40px; } .head h1 { font-size: 30px; line-height: 34px; }
  .head > div { flex: 0 0 auto !important; } .head .acts { flex-wrap: wrap; }
  .stats, .stats.co, .stats:not(.co) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ---- Menu tài khoản (account.js) ---- */
.acct { position: relative; padding: 0; }
.acct-btn { display: flex; align-items: center; gap: 10px; padding: 6px 10px 6px 6px; border: 1px solid transparent; border-radius: 6px; background: none; cursor: pointer; font: inherit; color: var(--ink); text-align: left; }
.acct-btn:hover, .acct-btn[aria-expanded="true"] { background: var(--hover); border-color: var(--line); }
.acct .av { width: 36px; height: 36px; border-radius: 999px; background: var(--link); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.acct .av.lg { width: 44px; height: 44px; font-size: 15px; }
.acct-who b { display: block; font-size: 14px; font-weight: 600; line-height: 1.25; }
.acct-who span { display: block; font-size: 12.5px; color: var(--muted); line-height: 1.3; }
.acct-menu { position: absolute; right: 0; top: calc(100% + 6px); width: 340px; max-width: calc(100vw - 24px); background: #fff; border: 1px solid var(--line); border-radius: 6px; box-shadow: var(--shadow-lg); z-index: 50; }
.acct-head { display: flex; gap: 12px; align-items: center; padding: 16px; border-bottom: 1px solid var(--line); }
.acct-head b { display: block; font-size: 15px; } .acct-head span, .acct-head small { display: block; font-size: 12.5px; color: var(--muted); overflow-wrap: anywhere; }
.acct-sec { padding: 8px 0; border-bottom: 1px solid var(--line); } .acct-sec:last-child { border-bottom: 0; }
.acct-lbl { padding: 4px 16px 6px; font-size: 12px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
.acct-row { display: flex; justify-content: space-between; gap: 10px; padding: 6px 16px; font-size: 14px; }
.acct-row em { font-style: normal; color: var(--muted); font-size: 13px; } .acct-row em.ok { color: var(--ok); font-weight: 600; }
.acct-row a { font-size: 13px; font-weight: 600; }
.acct-note { display: block; padding: 4px 16px 6px; font-size: 12px; color: var(--muted); line-height: 1.45; }
.acct-sec > a { display: block; padding: 9px 16px; text-decoration: none; color: var(--ink); font-size: 14px; font-weight: 600; }
.acct-sec > a:hover { background: var(--hover); }
.acct-sec > a small { display: block; font-weight: 400; font-size: 12.5px; color: var(--muted); }
.acct-sec > a.out { color: var(--bad); }
@media (max-width: 760px) { .acct-who { display: none; } }
