/* Mục công cụ miễn phí /cong-cu/ (19/10/2026). Nguồn trang: research/sinh-vu-opc/cong-cu/dung.py.
 * Một tệp kiểu cho mọi công cụ; công cụ mới thêm khối riêng ở cuối, tiền tố cc-<mã>-.
 * Chỉ token, bốn mốc 640 · 720 · 980 · 1080. */

/* ---------- hero ---------- */
.cc-hero { padding-bottom: 0; }
.cc-hero__inner { padding: 112px 32px 72px; }
.cc-hero__title { font-size: clamp(2rem, 1.4rem + 3vw, 3.25rem); margin-top: 18px; }
.cc-hero__notes { display: flex; flex-wrap: wrap; gap: 8px 12px; margin-top: 28px; }
.cc-hero__note { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-secondary);
  border: 1px solid var(--border-subtle); border-radius: var(--radius-pill); padding: 6px 14px; }
.cc-hero__note i { color: var(--accent); }
@media (max-width: 640px) { .cc-hero__inner { padding: 96px 16px 48px; } }

/* ---------- trang mục, phương án B (23/10/2026): kệ thẻ có ảnh + tấm xem nhanh (muc.js) ---------- */
.cc-mb { padding-bottom: 64px; }
.cc-mb-eb { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-caps); text-transform: uppercase; color: var(--text-secondary); }
.cc-mb-eb::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.cc-mb-nhan { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; line-height: 1.4; color: var(--text-secondary); }
.cc-mb-nhan i { color: var(--color-studio-blue); font-size: 16px; flex: none; }
.cc-mb-th { font-size: 14px; line-height: 1.5; color: var(--text-secondary); padding-left: 12px; border-left: 2px solid var(--color-warm-cream); }
.cc-mb-th b { font-weight: 600; color: var(--text-brand); }
.cc-mb-vai { display: flex; flex-wrap: wrap; gap: 4px; }
.cc-mb-vai span { font-size: 12px; line-height: 1.4; padding: 3px 8px; border-radius: var(--radius-sm); background: var(--surface-paper); color: var(--text-primary); }
.cc-mb-vai span.khop { background: var(--color-warm-cream); color: var(--color-deep-navy); font-weight: 600; }
.cc-mb-nut { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 24px; border-radius: var(--radius-md); background: var(--brand); color: var(--color-off-white); font-weight: 600; text-decoration: none; }
.cc-mb-nut i { transition: transform var(--dur-base) var(--ease-out); }
.cc-mb-nut:hover i { transform: translateX(3px); }
.cc-mb-nut:focus-visible { outline: none; box-shadow: var(--ring); }

.cc-mb__dau { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 32px; align-items: end; padding-top: 48px; padding-bottom: 24px; }
.cc-mb__dau h1 { font-family: var(--font-heading); font-weight: 600; font-size: clamp(2rem, 1.4rem + 2vw, 3rem); line-height: 1.1; letter-spacing: var(--tracking-snug); margin: 12px 0 0; color: var(--text-primary); }
.cc-mb__dau h1 em { font-style: normal; font-weight: inherit; color: var(--text-brand); }
.cc-mb__lead { margin: 0; font-size: 16px; line-height: 1.6; color: var(--text-secondary); }
.cc-mb__cam { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.cc-mb__cam li { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-secondary); }
.cc-mb__cam i { color: var(--color-studio-blue); font-size: 16px; }
/* phần đọc thêm của dải đầu: gập sẵn, bấm mới mở */
.cc-mb__them { margin-top: 8px; }
.cc-mb__them summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-size: 14px; font-weight: 600; color: var(--text-brand); }
.cc-mb__them summary::-webkit-details-marker { display: none; }
.cc-mb__them summary i { transition: transform var(--dur-base) var(--ease-out); }
.cc-mb__them[open] summary i { transform: rotate(180deg); }
.cc-mb__them summary:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }
.cc-mb__them > .cc-mb__lead { margin-top: 4px; }
@media (prefers-reduced-motion: reduce) { .cc-mb__them summary i { transition-duration: 0.001ms; } }

/* Khung chọn (28/10/2026): câu hỏi + hai ô chọn cùng cỡ (vai · ngành) trong MỘT khung, nhãn trên đầu ô.
   Màn rộng một hàng: câu hỏi chỉ chiếm bề chữ của nó, hai ô chia đều phần còn lại để tên ngành dài nhất
   (40 ký tự) đọc trọn ở 1440; dưới 1080 câu hỏi lên trên, hai ô chia đôi; điện thoại xếp dọc. */
.cc-mb__chon { padding-bottom: 24px; }
.cc-mb__khung { display: grid; grid-template-columns: auto minmax(0, 1fr) minmax(0, 1fr); align-items: end; gap: 16px 24px;
  padding: 20px 24px; border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); background: var(--surface-card); }
.cc-mb__hoi { align-self: center; max-width: 280px; margin: 0; font-family: var(--font-heading); font-size: 22px; font-weight: 600; line-height: 1.25; color: var(--text-primary); }
.cc-mb__truong { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cc-mb__nhan { font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.cc-mb__o { position: relative; display: flex; align-items: center; border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--surface-card);
  transition: border-color var(--dur-fast) var(--ease-out); }
.cc-mb__o > i { position: absolute; left: 14px; font-size: 20px; color: var(--color-studio-blue); pointer-events: none; }
.cc-mb__o > i:last-child { left: auto; right: 14px; font-size: 16px; color: var(--text-secondary); }
.cc-mb__o select { -webkit-appearance: none; appearance: none; width: 100%; min-height: 48px; padding: 0 40px 0 44px; border: 0; outline: none; background: transparent;
  font: inherit; font-size: 16px; color: var(--text-primary); text-overflow: ellipsis; cursor: pointer; }
.cc-mb__o:hover { border-color: var(--text-secondary); }
.cc-mb__o:focus-within { border-color: var(--brand); box-shadow: var(--ring); }
.cc-mb__o--co { border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }
.cc-mb__o--co > i:first-child { color: var(--text-brand); }

/* Nhóm công cụ: thẻ chỉ mục gạch chân, dính khi cuộn; gạch đè lên viền đáy của dải */
.cc-mb__loc { position: sticky; top: var(--cc-nav, 64px); z-index: var(--z-base); background: var(--surface-page); border-bottom: 1px solid var(--border-subtle); }
.cc-mb__nhom { display: flex; gap: 4px; margin-bottom: -1px; overflow-x: auto; scrollbar-width: none; min-width: 0;
  -webkit-mask-image: linear-gradient(to right, black calc(100% - 32px), transparent); mask-image: linear-gradient(to right, black calc(100% - 32px), transparent); }
.cc-mb__nhom::-webkit-scrollbar { display: none; }
.cc-mb__nhom button { flex: none; min-height: 52px; padding: 0 12px; border: 0; border-bottom: 2px solid transparent; background: none;
  color: var(--text-secondary); font: inherit; font-size: 15px; white-space: nowrap; cursor: pointer; transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out); }
.cc-mb__nhom button small { margin-left: 6px; font-size: 12px; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.cc-mb__nhom button:hover { color: var(--text-primary); }
.cc-mb__nhom button[aria-pressed="true"] { color: var(--text-primary); font-weight: 600; border-bottom-color: var(--accent); }
.cc-mb__nhom button:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }
@media (max-width: 1080px) {
  .cc-mb__khung { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .cc-mb__hoi { grid-column: 1 / -1; }
  /* sáu nhóm vừa một hàng tới 1024 (đo 28/10: dư 109px ở cỡ 15); hẹp hơn thì vuốt, mặt nạ báo còn */
  .cc-mb__nhom { gap: 0; }
  .cc-mb__nhom button { padding: 0 8px; font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) { .cc-mb__o, .cc-mb__nhom button { transition-duration: 0.001ms; } }

.cc-mb__luoi { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; padding-top: 24px; }
.cc-mb__trong { margin: 24px 0 0; color: var(--text-secondary); }
.cc-mt { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); background: var(--surface-card); color: var(--text-primary); text-decoration: none;
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out), opacity var(--dur-base) var(--ease-out); }
.cc-mt:hover { transform: translateY(-2px); border-color: var(--border-strong); box-shadow: var(--shadow-md); }
.cc-mt:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-mt--to { grid-column: span 2; }
.cc-mb__luoi--loc .cc-mt--to { grid-column: auto; }
.cc-mt--mo { opacity: .45; }
.cc-mt--mo:hover, .cc-mt--mo:focus-visible { opacity: 1; }
.cc-mt__hinh { position: relative; display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--surface-paper); border-bottom: 1px solid var(--border-subtle); }
.cc-mt--to .cc-mt__hinh { aspect-ratio: 16 / 7; }
.cc-mb__luoi--loc .cc-mt--to .cc-mt__hinh { aspect-ratio: 16 / 9; }
.cc-mt__hinh img, .cc-xn__hinh img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cc-mt__hinh img { transition: transform var(--dur-reveal) var(--ease-out); }
.cc-mt:hover .cc-mt__hinh img { transform: scale(1.04); }
.cc-mt__than { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 16px 20px 20px; min-width: 0; }
/* tên công cụ là tiêu đề thẻ, câu hỏi là dòng phụ (28/10/2026) */
.cc-mt__ten { margin: 0; font-family: var(--font-heading); font-weight: 600; font-size: 20px; line-height: 1.25; color: var(--text-primary); text-wrap: balance; }
.cc-mt--to .cc-mt__ten { font-size: 24px; }
.cc-mb__luoi--loc .cc-mt--to .cc-mt__ten { font-size: 20px; }
.cc-mt__hoi { font-size: 15px; line-height: 1.5; color: var(--text-secondary); }
.cc-mb__luoi--loc .cc-mt--to .cc-mb-th { display: none; }
.cc-mt__ra { margin-top: auto; padding-top: 8px; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.cc-mt--to .cc-mt__ra { flex-direction: row; justify-content: space-between; align-items: center; gap: 16px; }
.cc-mb__luoi--loc .cc-mt--to .cc-mt__ra { flex-direction: column; align-items: flex-start; gap: 10px; }
.cc-mt__ra b { flex: none; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 600; color: var(--text-brand); }
.cc-mt__ra b i { transition: transform var(--dur-base) var(--ease-out); }
.cc-mt:hover .cc-mt__ra b i { transform: translateX(3px); }
@media (max-width: 1080px) { .cc-mb__luoi { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 980px) {
  .cc-mb__dau { grid-template-columns: 1fr; gap: 16px; padding-top: 32px; }
  .cc-mb__luoi { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
/* Điện thoại: thẻ thành một hàng (ảnh vuông 112px · chữ), thẻ lớn bằng thẻ thường; vai vuốt ngang một hàng */
@media (max-width: 640px) {
  .cc-mb { padding-bottom: 40px; }
  .cc-mb__dau { padding-top: 24px; padding-bottom: 16px; }
  .cc-mb__lead { font-size: 15px; line-height: 1.55; }
  .cc-mb__khung { grid-template-columns: 1fr; gap: 12px; padding: 16px; }
  .cc-mb__hoi { font-size: 18px; }
  .cc-mb__nhom { margin-right: -16px; padding-right: 16px; }
  .cc-mb__luoi { grid-template-columns: 1fr; gap: 12px; padding-top: 16px; }
  .cc-mt { flex-direction: row; border-radius: var(--radius-md); }
  .cc-mt--to { grid-column: auto; }
  .cc-mt__hinh, .cc-mt--to .cc-mt__hinh, .cc-mb__luoi--loc .cc-mt--to .cc-mt__hinh { aspect-ratio: auto; width: 112px; flex: none; border-bottom: 0; border-right: 1px solid var(--border-subtle); }
  .cc-mt__than { padding: 12px 14px; gap: 6px; }
  .cc-mt__ten, .cc-mt--to .cc-mt__ten, .cc-mb__luoi--loc .cc-mt--to .cc-mt__ten { font-size: 17px; }
  .cc-mt__hoi { font-size: 14px; line-height: 1.45; }
  .cc-mt .cc-mb-th, .cc-mt__ra b { display: none; }
  .cc-mt__ra { padding-top: 2px; }
}

/* Tấm xem nhanh */
.cc-xn-nen { position: fixed; inset: 0; z-index: var(--z-overlay); background: color-mix(in srgb, var(--color-deep-navy) 45%, transparent); opacity: 0; pointer-events: none; transition: opacity var(--dur-base) var(--ease-out); }
.cc-xn { position: fixed; top: 0; right: 0; bottom: 0; z-index: var(--z-modal); width: min(520px, 100%); display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
  background: var(--surface-card); visibility: hidden; transform: translateX(100%); transition: transform var(--dur-slow) var(--ease-out), visibility 0s var(--dur-slow); }
.cc-xn-mo { overflow: hidden; }
.cc-xn-mo .cc-xn-nen { opacity: 1; pointer-events: auto; }
.cc-xn-mo .cc-xn { visibility: visible; transform: none; transition: transform var(--dur-slow) var(--ease-out); }
.cc-xn__ruot { display: flex; flex-direction: column; flex: 1; }
.cc-xn__hinh { position: relative; flex: none; aspect-ratio: 16 / 9; overflow: hidden; background: var(--surface-paper); }
.cc-xn__hinh--mota { aspect-ratio: 3 / 2; }
.cc-xn__dong { position: absolute; top: 12px; right: 12px; z-index: 1; width: 44px; height: 44px; display: grid; place-items: center; border: 0; border-radius: var(--radius-md);
  background: var(--surface-card); color: var(--text-primary); font-size: 20px; cursor: pointer; box-shadow: var(--shadow-sm); }
.cc-xn__dong:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-xn__than { flex: 1; display: flex; flex-direction: column; gap: 20px; padding: 24px 28px 32px; }
.cc-xn__ten { margin: 8px 0 0; font-family: var(--font-heading); font-weight: 600; font-size: 30px; line-height: 1.15; color: var(--text-primary); }
.cc-xn__muc { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 12px; margin: 0; padding-top: 16px; border-top: 1px solid var(--border-subtle); font-size: 15px; line-height: 1.55; }
.cc-xn__muc dt { padding-top: 3px; font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-wide); text-transform: uppercase; color: var(--text-secondary); }
.cc-xn__muc dd { margin: 0; text-wrap: pretty; }
.cc-xn__ten, .cc-mb-th { text-wrap: balance; }
.cc-xn__muc dd.cc-mb-th { font-size: 15px; color: var(--text-primary); }
.cc-xn__ba { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; counter-reset: xn; }
.cc-xn__ba li { padding: 12px; border-radius: var(--radius-md); background: var(--surface-page); font-size: 13px; line-height: 1.45; }
.cc-xn__ba li::before { counter-increment: xn; content: counter(xn); display: block; font-family: var(--font-heading); font-weight: 600; font-size: 20px; color: var(--text-brand); }
.cc-xn__chan { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }

/* Dải xem nhanh thông minh (27/10/2026, thay tấm xổ bên phải ở màn rộng): mở ngay dưới hàng thẻ vừa bấm, rộng bằng kệ,
   không nền mờ; mũi nhọn chỉ lên đúng thẻ. Điện thoại vẫn dùng tấm trượt từ đáy (.cc-xn). muc.js dời khối vào lưới. */
.cc-mt[aria-expanded="true"] { border-color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }
.cc-mt__hop, .cc-mt__do { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 2px 8px; border-radius: var(--radius-sm); font-size: 12px; font-weight: 600; line-height: 1.6; }
.cc-mt__hop { background: var(--surface-paper); color: var(--text-brand); }
.cc-mt__do { background: var(--color-studio-blue); color: var(--color-off-white); }
.cc-xd { position: relative; grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); margin: 4px 0;
  border: 1px solid var(--border-strong); border-radius: var(--radius-lg); background: var(--surface-card); box-shadow: var(--shadow-md);
  scroll-margin-top: calc(var(--cc-nav, 64px) + 80px); scroll-margin-bottom: 16px; animation: cc-xd-vao var(--dur-base) var(--ease-out); }
.cc-xd[hidden], .cc-xn__ng[hidden] { display: none; }
@keyframes cc-xd-vao { from { opacity: 0; transform: translateY(-8px); } }
.cc-xd__mui { position: absolute; top: -9px; left: var(--mui, 48px); width: 16px; height: 16px; margin-left: -8px; transform: rotate(45deg);
  background: var(--surface-card); border-top: 1px solid var(--border-strong); border-left: 1px solid var(--border-strong); }
.cc-xd .cc-xn__ruot { display: contents; }
.cc-xd .cc-xn__hinh { align-self: stretch; aspect-ratio: auto; min-height: 320px; border-radius: var(--radius-lg) 0 0 var(--radius-lg); margin: 0; }
.cc-xd .cc-xn__than { padding: 28px 72px 28px 32px; gap: 16px; }
.cc-xd .cc-xn__ten { margin-top: 4px; font-size: 28px; }
.cc-xd .cc-xn__muc { grid-template-columns: 104px minmax(0, 1fr); gap: 8px 12px; padding-top: 12px; }
.cc-xd .cc-xn__ba { display: none; }
.cc-xn__ten:focus, .cc-xn__ten:focus-visible { outline: none; box-shadow: none; }
.cc-xn__ng { display: flex; flex-direction: column; gap: 4px; padding: 16px 16px 12px; border-radius: var(--radius-md); background: var(--surface-paper); font-size: 15px; line-height: 1.55; }
.cc-xn__ng p { margin: 0; }
.cc-xn__ng p b { color: var(--text-brand); }
.cc-xn__ng button { align-self: flex-start; min-height: 44px; padding: 0; border: 0; background: none; font: inherit; font-size: 14px; font-weight: 600; color: var(--text-brand); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; margin: -6px 0 -10px; }
.cc-xn__ng select { min-height: 44px; max-width: 100%; padding: 0 12px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface-card); font: inherit; font-size: 16px; color: var(--text-primary); }
.cc-xn__lo { display: flex; flex-direction: column; gap: 8px; }
.cc-xn__lo ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; counter-reset: b; }
.cc-xn__lo li { display: inline-flex; align-items: center; counter-increment: b; }
.cc-xn__lo a, .cc-xn__lo b { display: inline-flex; align-items: center; min-height: 36px; padding: 0 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); }
.cc-xn__lo a::before, .cc-xn__lo b::before { content: counter(b); margin-right: 8px; font-weight: 600; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.cc-xn__lo a { color: var(--text-primary); text-decoration: none; transition: border-color var(--dur-fast) var(--ease-out); }
.cc-xn__lo a:hover { border-color: var(--border-strong); text-decoration: underline; text-underline-offset: 3px; }
.cc-xn__lo a:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-xn__lo b { border-color: var(--brand); background: var(--surface-paper); color: var(--text-brand); font-weight: 600; }
.cc-xn__lo b::before { color: var(--text-brand); }
.cc-xn mark, .cc-xd mark { background: var(--color-warm-cream); color: inherit; border-radius: 2px; }
.cc-xn__ng mark { background: transparent; box-shadow: inset 0 -2px 0 var(--brand); border-radius: 0; }
.cc-xn__chan [data-gio] b { font-weight: 600; color: var(--text-primary); }
@media (max-width: 980px) {
  .cc-xd { grid-template-columns: 1fr; }
  .cc-xd .cc-xn__hinh { border-radius: var(--radius-lg) var(--radius-lg) 0 0; aspect-ratio: 21 / 8; min-height: 0; width: 100%; }
  .cc-xd .cc-xn__than { padding: 24px; }
}
@media (max-width: 640px) {
  .cc-xn { top: auto; width: 100%; max-height: 88vh; max-height: 88dvh; border-radius: var(--radius-lg) var(--radius-lg) 0 0; transform: translateY(100%); }
  /* nút đóng dính đầu tấm khi cuộn, dải đệm dính để chữ không chạm mép bo (gac-ui-ux 28/10) */
  .cc-xn::before { content: ""; position: sticky; top: 0; z-index: 1; flex: none; height: 16px; margin-bottom: -16px; background: var(--surface-card); border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
  .cc-xn__dong { position: sticky; top: 8px; z-index: 2; flex: none; align-self: flex-end; margin: 8px 8px -52px 0; }
  .cc-xn__lo ol { flex-direction: column; align-items: stretch; }
  .cc-xn__lo a, .cc-xn__lo b { min-height: 44px; width: 100%; }
  .cc-xn__hinh { aspect-ratio: 21 / 8; }
  .cc-xn__hinh--mota { aspect-ratio: 16 / 9; }
  .cc-xn__than { padding: 20px 16px 0; gap: 16px; }
  .cc-xn__ten { font-size: 24px; }
  .cc-xn__muc { grid-template-columns: 1fr; gap: 4px; }
  .cc-xn__muc dd + dt { margin-top: 8px; }
  .cc-xn__ba { display: none; }
  .cc-xn__chan { position: sticky; bottom: 0; background: var(--surface-card); padding: 12px 0 calc(20px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--border-subtle); }
  .cc-xn__chan .cc-mb-nut { flex: 1 1 100%; justify-content: center; white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  .cc-mt, .cc-mt__hinh img, .cc-mt__ra b i, .cc-mb-nut i, .cc-xn, .cc-xn-nen, .cc-xn-mo .cc-xn, .cc-xn__lo a { transition-duration: 0.001ms; }
  .cc-xd { animation: none; }
  .cc-mt:hover .cc-mt__hinh img { transform: none; }
}

/* ---------- khung máy ---------- */
.cc-may-wrap { padding: 24px 0 64px; }
.cc-may { background: var(--surface-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); padding: 32px; }
@media (max-width: 640px) { .cc-may-wrap { padding: 16px 0 48px; } .cc-may-wrap > .container { padding-left: 12px; padding-right: 12px; } .cc-may { padding: 20px 16px; border-radius: var(--radius-md); } }
.cc-noscript { margin: 0; color: var(--text-secondary); }
.cc-buocs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
@media (max-width: 980px) { .cc-buocs { grid-template-columns: 1fr; gap: 20px; } }
.cc-buoc { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.cc-buoc__nhan { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; letter-spacing: 0.04em; color: var(--text-secondary); }
.cc-buoc__so { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px;
  background: var(--color-deep-navy); color: var(--color-off-white); flex: none; }
.cc-chon { display: flex; gap: 8px; flex-wrap: wrap; }
.cc-chon button { min-height: 44px; padding: 0 18px; border-radius: var(--radius-md); border: 1px solid var(--border-strong);
  background: var(--surface-card); color: var(--text-primary); font: 600 15px var(--font-sans); cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px; transition: border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out); }
.cc-chon button[aria-pressed="true"] { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 7%, var(--surface-card)); color: var(--text-brand); }
.cc-chon button:focus-visible, .cc-tha:focus-within, .cc-o:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-tha { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 132px;
  padding: 20px; text-align: center; border: 1.5px dashed var(--border-strong); border-radius: var(--radius-md); background: var(--surface-page);
  color: var(--text-secondary); font-size: 14px; cursor: pointer; transition: border-color var(--dur-fast) var(--ease-out); }
.cc-tha:hover, .cc-tha[data-keo] { border-color: var(--brand); }
.cc-tha[hidden] { display: none; }
.cc-tha i { font-size: 28px; color: var(--text-brand); }
.cc-tha strong { color: var(--text-primary); font-size: 15px; }
.cc-tha input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.cc-mau { align-self: flex-start; background: none; border: 0; padding: 8px 0; min-height: 44px; font: 600 14px var(--font-sans);
  color: var(--text-brand); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.cc-mau:hover { text-decoration: underline; text-underline-offset: 3px; }
.cc-o { width: 100%; max-width: 200px; min-height: 44px; padding: 0 12px; border-radius: var(--radius-sm); border: 1px solid var(--border-strong);
  background: var(--surface-card); color: var(--text-primary); font: 16px var(--font-sans);
  box-shadow: inset 0 1px 2px rgba(3, 29, 68, .06); transition: border-color var(--dur-fast) var(--ease-out); }
/* Nền thẻ + viền đậm: nền lõm xám đọc ra như ô đã khoá (soát 21/10, việc 13) */
.cc-o:hover { border-color: var(--text-secondary); }
.cc-o::placeholder { color: var(--text-secondary); opacity: .7; }
.cc-goi-y { font-size: 13px; color: var(--text-secondary); margin: 0; line-height: 1.5; }
.cc-loi-tep { color: var(--text-status-critical); font-size: 14px; margin: 0; }

/* ---------- kết quả ---------- */
.cc-kq { margin-top: 32px; padding-top: 32px; border-top: 1px solid var(--hairline); }
.cc-app .cc-kq { margin-top: 0; padding-top: 0; border-top: 0; scroll-margin-top: 80px; }
.cc-kq[hidden] { display: none; }
.cc-kq__h { font-family: var(--font-heading); font-weight: 600; font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); margin: 0 0 8px; line-height: 1.2; }
.cc-kq__h em { font-style: normal; color: var(--text-brand); }
.cc-kq__ket { margin: 0 0 24px; color: var(--text-secondary); font-size: 16px; }
.cc-khungs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; align-items: start; }
@media (max-width: 720px) { .cc-khungs { grid-template-columns: 1fr; } }
.cc-khung { min-width: 0; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); padding: 20px; background: var(--surface-page); }
.cc-khung__ten { font-weight: 600; font-size: 15px; margin: 0; }
.cc-khung__phu { font-size: 13px; color: var(--text-secondary); margin: 4px 0 16px; }
.cc-soi { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 12px; }
.cc-soi li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 4px 16px; align-items: start;
  padding: 16px 20px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-soi__dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 7px; background: var(--color-success); }
.cc-soi__ten { font-weight: 600; font-size: 15px; }
.cc-soi__loi { grid-column: 2 / 4; margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-secondary); }
.cc-soi__muc { font-size: 13px; font-weight: 600; white-space: nowrap; color: var(--text-status-success); }
.cc-soi__goi-y { display: inline-block; margin-right: 8px; padding: 0 8px; border: 1px solid var(--border-strong); border-radius: var(--radius-pill);
  font-size: 12px; font-weight: 500; line-height: 20px; color: var(--text-secondary); vertical-align: 1px; }
.cc-soi__so { font-variant-numeric: tabular-nums; color: var(--text-secondary); font-weight: 400; margin-left: 6px; }
.cc-soi li[data-muc="vua"] .cc-soi__dot { background: var(--color-warning); }
.cc-soi li[data-muc="vua"] .cc-soi__muc { color: var(--text-status-warning); }
.cc-soi li[data-muc="yeu"] .cc-soi__dot { background: var(--color-danger); }
.cc-soi li[data-muc="yeu"] .cc-soi__muc { color: var(--text-status-critical); }
@media (max-width: 640px) {
  .cc-soi li { grid-template-columns: auto minmax(0, 1fr); padding: 14px 16px; }
  .cc-soi__muc { grid-column: 2; }
  .cc-soi__loi { grid-column: 1 / 3; }
}
.cc-ghi-do { font-size: 13px; color: var(--text-secondary); margin: 16px 0 0; display: flex; gap: 8px; line-height: 1.5; }
.cc-ghi-do i { flex: none; margin-top: 2px; }
/* bước kế tiếp sau bản soi: một hàng hành động trên nền giấy, không phải khối quảng cáo navy */
.cc-cta { margin-top: 32px; padding: 24px; border-radius: var(--radius-lg); background: var(--surface-paper); border: 1px solid var(--hairline);
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 32px; align-items: center; }
.cc-cta h2 { font-family: var(--font-heading); font-weight: 600; font-size: 22px; margin: 0; line-height: 1.25; color: var(--text-primary); }
.cc-cta h2 em { font-style: normal; color: var(--text-brand); }
.cc-cta p { margin: 8px 0 0; color: var(--text-secondary); font-size: 14px; line-height: 1.6; }
.cc-cta__dv { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 12px; }
.cc-cta__dv a { color: var(--text-brand); font-size: 14px; font-weight: 600; text-underline-offset: 3px; }
.cc-cta__tiep { display: inline-flex; align-items: center; gap: 6px; }
.cc-cta__tiep .ph, .cc-ket__gui .ph { transition: transform var(--dur-fast) var(--ease-out); }
.cc-cta__tiep:hover .ph, .cc-ket__gui:hover .ph { transform: translateX(3px); }
/* đường gửi Sinh Vũ ngay dưới thẻ kết luận khi có chỗ cần sửa */
.cc-ket__gui { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; margin-top: 8px; padding: 10px 16px;
  border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); color: var(--text-brand); font-weight: 600; font-size: 15px; text-decoration: none; }
.cc-ket__gui:hover { border-color: var(--border-strong); }
/* kết quả ổn: dòng mời nhẹ, không khung, chữ thường (không bắt buộc) */
.cc-ket__gui--phu { border-color: transparent; background: none; padding: 8px 4px; font-weight: 500; font-size: 14px; color: var(--text-secondary); }
@media (prefers-reduced-motion: reduce) { .cc-cta__tiep .ph, .cc-ket__gui .ph { transition: none; } }
@media (max-width: 1080px) { .cc-app .cc-cta { grid-template-columns: 1fr; } .cc-app .cc-cta .sv-btn { justify-self: start; } }
@media (max-width: 720px) { .cc-cta { grid-template-columns: 1fr; padding: 20px 16px; } .cc-cta .sv-btn { width: 100%; white-space: normal; } }

/* ---------- vì sao · hỏi đáp ---------- */
.cc-ys { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
@media (max-width: 980px) { .cc-ys { grid-template-columns: 1fr; gap: 16px; } }
.cc-y { padding: 24px; border: 1px solid var(--hairline); border-radius: var(--radius-lg); background: var(--surface-card); }
.cc-y i { font-size: 26px; color: var(--text-brand); }
.cc-y h3 { font-family: var(--font-heading); font-weight: 600; font-size: 20px; margin: 12px 0 8px; }
.cc-y p { margin: 0; font-size: 15px; line-height: 1.65; color: var(--text-secondary); }
.cc-liens { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 28px; }
.cc-lien { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-weight: 600; font-size: 15px; color: var(--text-brand); text-decoration: none; }
.cc-lien i { transition: transform var(--dur-base) var(--ease-out); }
.cc-lien:hover i { transform: translateX(3px); }
/* Mũi tên đi xuyên khung như toàn site (n-di ở assets/ds/nhip.css, hệ trạng thái 24/10/2026); biểu tượng khác vẫn dịch 3px. */
@media (hover: hover) and (pointer: fine) {
  :is(.cc-mb-nut, .cc-cta__tiep, .cc-ket__gui, .cc-lien):hover i.ph-arrow-right,
  .cc-mt:hover .cc-mt__ra b i.ph-arrow-right { display: inline-block; transform: none; animation: n-di var(--n-cham, 480ms) both; }
}
@media (prefers-reduced-motion: reduce) { :is(.cc-mb-nut, .cc-cta__tiep, .cc-ket__gui, .cc-lien, .cc-mt) i.ph-arrow-right { animation: none !important; } }
.cc-hois { max-width: var(--container-text); }
.cc-hois .sv-sh { margin-bottom: 24px; }
.cc-hois .sv-sh__body { grid-template-columns: 1fr; }
.cc-hoi { border-bottom: 1px solid var(--hairline); }
.cc-hoi summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 16px; align-items: center;
  min-height: 56px; padding: 12px 0; font-weight: 600; font-size: 16px; }
.cc-hoi summary::-webkit-details-marker { display: none; }
.cc-hoi summary i { flex: none; transition: transform var(--dur-base) var(--ease-out); }
.cc-hoi[open] summary i { transform: rotate(45deg); }
.cc-hoi p { margin: 0 0 16px; color: var(--text-secondary); line-height: 1.7; }

/* ================= công cụ: thử ở cỡ thật (cc-tct-) ================= */
.cc-tct-dt { width: 100%; max-width: 360px; margin: 0 auto; padding: 12px; border-radius: var(--radius-lg);
  background: var(--color-white); border: 1px solid var(--border-subtle); }
.cc-tct-luoi { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cc-tct-o { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.cc-tct-anh { aspect-ratio: 1; border-radius: var(--radius-sm); background: var(--color-white); overflow: hidden;
  display: grid; place-items: center; outline: 1px solid color-mix(in srgb, var(--color-charcoal) 8%, transparent); }
.cc-tct-anh canvas { width: 100%; height: 100%; object-fit: contain; display: block; }
.cc-tct-gia { height: 8px; border-radius: 4px; background: var(--color-soft-gray); }
.cc-tct-gia--ngan { width: 55%; }
.cc-tct-gia--dam { width: 35%; background: color-mix(in srgb, var(--color-signal-red) 35%, var(--color-soft-gray)); }
.cc-tct-khac { background: color-mix(in srgb, var(--color-soft-gray) 55%, var(--color-white)); outline: 0; }
.cc-tct-ke__hop { opacity: 0.7; }
.cc-tct-ke { position: relative; display: flex; align-items: flex-end; justify-content: center; gap: 10px; min-height: 150px; padding: 20px 12px 0;
  border-radius: var(--radius-sm); background: color-mix(in srgb, var(--color-warm-cream) 22%, var(--color-white)); overflow: hidden; }
.cc-tct-ke::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 10px; background: var(--color-studio-blue); }
.cc-tct-ke__hop { flex: none; margin-bottom: 10px; background: var(--color-soft-gray); border-radius: 2px; }
.cc-tct-ke canvas { flex: none; display: block; margin-bottom: 10px; image-rendering: auto; }
.cc-tct-tron { display: flex; align-items: flex-end; gap: 20px; flex-wrap: wrap; }
.cc-tct-tron__mot { display: flex; flex-direction: column; align-items: center; gap: 8px; font-size: 12px; color: var(--text-secondary); }
.cc-tct-tron canvas { border-radius: 50%; display: block; }
.cc-tct-hai { display: flex; gap: 12px; }
.cc-tct-nen { padding: 16px; border-radius: var(--radius-sm); background: var(--color-white); border: 1px solid var(--border-subtle); }
.cc-tct-nen--toi { background: var(--color-charcoal); border-color: var(--color-charcoal); }
.cc-tct-tab { display: flex; flex-direction: column; gap: 10px; }
.cc-tct-tab__the { display: flex; align-items: center; gap: 8px; max-width: 300px; padding: 8px 12px; border-radius: var(--radius-sm) var(--radius-sm) 0 0;
  background: var(--color-soft-gray); font-size: 12px; color: var(--color-charcoal); }
.cc-tct-tab__the canvas { flex: none; display: block; }
.cc-tct-tab__the span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 640px) {
  .cc-khung { padding: 14px 12px; }
  .cc-tct-dt { padding: 8px; }
  .cc-tct-hai { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  .cc-lien i, .cc-hoi summary i, .cc-chon button { transition-duration: 0.001ms; }
}
.cc-cta .sv-btn__inner { display: inline-flex; align-items: center; gap: 8px; }

/* ================= công cụ: bản đồ điểm chạm (cc-dc-) ================= */
.cc-buocs--hai { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
@media (max-width: 980px) { .cc-buocs--hai { grid-template-columns: 1fr; } }
.cc-dc-chon { max-width: none; }
.cc-dc-nhanh button { font-weight: 500; font-size: 14px; }
.cc-dc-changs { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; counter-reset: none; }
@media (max-width: 1080px) { .cc-dc-changs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .cc-dc-changs { grid-template-columns: 1fr; } }
.cc-dc-chang { min-width: 0; padding: 20px 16px; border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md); background: var(--surface-page); }
.cc-dc-chang[data-roi] { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 5%, var(--surface-card)); }
.cc-dc-chang__so { font-family: var(--font-heading); font-weight: 600; font-size: 13px; letter-spacing: 0.14em; color: var(--text-secondary); }
.cc-dc-chang h3 { font-family: var(--font-heading); font-weight: 600; font-size: 20px; margin: 0; line-height: 1.2; }
.cc-dc-chang p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
.cc-dc-chang__nhan { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--text-brand); }
.cc-dc-chips { list-style: none; margin: 4px 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.cc-dc-chips li { font-size: 12px; line-height: 1.4; padding: 4px 10px; border-radius: var(--radius-sm); background: var(--surface-card); border: 1px solid var(--hairline); }
.cc-dc-chang__loi strong { color: var(--text-primary); font-weight: 600; }
.cc-dc-roi { margin-top: 20px; padding: 20px 24px; border-left: 3px solid var(--brand); border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--surface-paper); }
.cc-dc-roi__h { display: flex; align-items: baseline; gap: 8px; font-weight: 600; color: var(--text-brand); margin: 0 0 8px; }
.cc-dc-roi p { margin: 0 0 8px; line-height: 1.65; }
.cc-dc-roi ul { margin: 0 0 4px; padding-left: 20px; line-height: 1.7; }
.cc-dc-h3 { font-family: var(--font-heading); font-weight: 600; font-size: clamp(1.3rem, 1.1rem + 0.8vw, 1.6rem); margin: 40px 0 4px; }
.cc-dc-cham { display: grid; gap: 12px; margin-top: 16px; }
.cc-dc-mot { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px 24px; align-items: center; padding: 16px 20px;
  border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
@media (max-width: 720px) { .cc-dc-mot { grid-template-columns: 1fr; padding: 14px 16px; } }
.cc-dc-mot__ten { margin: 0; font-weight: 600; }
.cc-dc-mot__vi { margin: 4px 0 0; font-size: 14px; color: var(--text-secondary); line-height: 1.55; }
.cc-dc-ba { flex-wrap: nowrap; }
.cc-dc-ba button { padding: 0 12px; font-size: 14px; font-weight: 500; }
.cc-dc-ba button[aria-checked="true"] { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 7%, var(--surface-card)); color: var(--text-brand); font-weight: 600; }
.cc-dc-ba button[aria-checked="true"][data-muc="yeu"] { border-color: var(--color-danger); color: var(--text-status-critical); background: color-mix(in srgb, var(--color-danger) 6%, var(--surface-card)); }
@media (max-width: 640px) { .cc-dc-ba { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); } .cc-dc-ba button { justify-content: center; padding: 0 6px; font-size: 13px; } }
.cc-dc-ket { margin-top: 32px; font-weight: 600; color: var(--text-primary); }
.cc-dc-chang details > * + * { margin-top: 8px; }
.cc-dc-chang summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 4px 10px; align-items: baseline; }
.cc-dc-chang summary::-webkit-details-marker { display: none; }
.cc-dc-chang summary .cc-dc-chang__nhan { grid-column: 1 / 4; }
.cc-dc-chang__mo { grid-column: 3; grid-row: 1; align-self: center; font-size: 18px; color: var(--text-secondary); transition: transform var(--dur-base) var(--ease-out); }
.cc-dc-chang details[open] .cc-dc-chang__mo { transform: rotate(180deg); }
.cc-dc-chang__mo { display: none; }
.cc-dc-chang summary { cursor: default; pointer-events: none; }
@media (max-width: 640px) {
  .cc-dc-chang { padding: 14px 16px; }
  .cc-dc-chang summary { min-height: 44px; cursor: pointer; pointer-events: auto; }
  .cc-dc-chang__mo { display: inline-block; }
}
@media (prefers-reduced-motion: reduce) { .cc-dc-chang__mo { transition-duration: 0.001ms; } }

/* ================= công cụ: kiểm tra tệp in (cc-in-) ================= */
.cc-in-the { margin: 0 0 8px; }
.cc-in-ct { margin-top: 16px; }
.cc-in-ct ul { margin: 0 0 16px; padding-left: 20px; line-height: 1.7; font-size: 14px; color: var(--text-secondary); }
.cc-in-ct strong { color: var(--text-primary); font-weight: 600; }
@media (max-width: 640px) {
  .cc-chon--luoi { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cc-chon--luoi button { padding: 8px 10px; font-size: 14px; line-height: 1.3; justify-content: flex-start; text-align: left; }
}

/* ================= bàn làm việc của một công cụ (20/10/2026) =================
   Luật trình bày công cụ (khác trang đọc): (1) công cụ lên màn đầu, đầu trang là dải gọn chứ không phải hero;
   (2) trái bảng nhập, phải vùng kết quả; màn rộng bảng nhập dính khi cuộn để đổi lựa chọn mà vẫn thấy kết quả;
   (3) vùng kết quả không bao giờ trống: chưa có tệp thì nói khách sẽ nhận gì và cho xem bằng mẫu;
   (4) có kết quả: thẻ kết luận đứng đầu, rồi khung xem, bản soi, một hàng hành động; (5) tệp đã nhận thu về một
   dòng có nút Đổi tệp; (6) dưới 980 thành một cột, bảng nhập trên, kết quả liền dưới. */
.cc-dau { background: var(--color-deep-navy); color: var(--text-primary); padding: 20px 0 24px; }
.cc-dau__crumb { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 13px; color: var(--text-secondary); }
.cc-dau__crumb a { color: var(--text-secondary); text-decoration: none; min-height: 32px; display: inline-flex; align-items: center; }
.cc-dau__crumb a:hover { color: var(--text-primary); text-decoration: underline; text-underline-offset: 3px; }
.cc-dau__crumb i { font-size: 12px; }
.cc-dau__h1 { font-family: var(--font-heading); font-weight: 600; font-size: clamp(1.75rem, 1.35rem + 1.4vw, 2.5rem); line-height: 1.15;
  letter-spacing: var(--tracking-snug); margin: 4px 0 0; color: var(--text-primary); }
.cc-dau__h1 em { font-style: normal; color: var(--color-warm-cream); }
@media (max-width: 640px) { .cc-dau { padding: 12px 0 16px; } }
/* QC 26/10: chế độ ứng dụng ở điện thoại, dải đầu không ăn quá 1/5 màn. Màn Nhập: đường dẫn chỉ còn lối về
   Công cụ miễn phí (một dòng); màn Kết quả: bỏ đường dẫn, tiêu đề nhỏ lại để kết luận lên gần đỉnh */
@media (max-width: 640px) {
  html.cc-ung .cc-dau__crumb > a:first-child, html.cc-ung .cc-dau__crumb > i, html.cc-ung .cc-dau__crumb > span { display: none; }
  html.cc-ung .cc-dau { padding: 4px 0 12px; }
  /* Vòng 2 (26/10): tiêu đề 22px ở màn Nhập để đỉnh khu công cụ về quanh 150px (tiêu đề một dòng) */
  html.cc-ung .cc-dau__h1 { font-size: 1.375rem; margin-top: 0; }
  html.cc-ung .cc-dau__crumb a { min-height: 28px; }
  html.cc-ung:has(.cc-app[data-man="ra"]) .cc-dau__crumb { display: none; }
  html.cc-ung:has(.cc-app[data-man="ra"]) .cc-dau { padding: 12px 0; }
  html.cc-ung:has(.cc-app[data-man="ra"]) .cc-dau__h1 { font-size: 1.25rem; }
}

/* Về công cụ này (24/10/2026): trang mục đã giới thiệu, nên ở trang chi tiết lời dẫn, dùng khi, cam kết, vì sao,
   hỏi đáp gập một khối ở đáy; mặc định đóng, khách dùng công cụ không phải đọc lại */
.cc-ve-wrap { padding: 0 0 64px; }
.cc-ve { border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.cc-ve > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 56px; font-family: var(--font-heading); font-weight: 600; font-size: 18px; color: var(--text-primary); }
.cc-ve > summary::-webkit-details-marker { display: none; }
.cc-ve > summary i { flex: none; color: var(--text-brand); transition: transform var(--dur-base) var(--ease-out); }
.cc-ve[open] > summary i { transform: rotate(180deg); }
.cc-ve__ruot { padding: 8px 0 32px; max-width: 960px; }
.cc-ve__mota { margin: 0 0 24px; max-width: 640px; }
.cc-ve__mota img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius-md); border: 1px solid var(--border-subtle); background: var(--surface-paper); }
.cc-ve__mota figcaption { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 12px; font-size: 14px; line-height: 1.55; color: var(--text-secondary); }
.cc-ve__mota figcaption b { display: block; font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-wide); text-transform: uppercase; color: var(--text-brand); }
@media (max-width: 640px) { .cc-ve__mota figcaption { grid-template-columns: 1fr; gap: 8px; } }
.cc-ve__dan { margin: 0; max-width: 640px; font-size: 16px; line-height: 1.7; color: var(--text-secondary); }
.cc-ve__ruot h3 { font-size: 13px; font-weight: 600; letter-spacing: var(--tracking-caps); text-transform: uppercase; color: var(--text-brand); margin: 24px 0 8px; }
.cc-ve__khi { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cc-ve__khi li { font-size: 14px; line-height: 1.45; padding: 6px 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); }
.cc-ve__ghi { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 20px; font-size: 13px; color: var(--text-secondary); }
.cc-ve__ghi li { display: inline-flex; align-items: center; gap: 6px; }
.cc-ve__ghi i { color: var(--color-success); }
.cc-ve__h2 { font-family: var(--font-heading); font-weight: 600; font-size: 24px; line-height: 1.25; margin: 40px 0 0; color: var(--text-primary); }
.cc-ve__h2 em { font-style: normal; color: var(--color-bordeaux); }
.cc-ve .cc-ys { margin-top: 20px; }
.cc-ve .cc-y h3 { font-size: 20px; font-weight: 600; letter-spacing: normal; text-transform: none; color: var(--text-primary); margin: 12px 0 8px; }
.cc-ve .cc-hois { margin-top: 12px; }
@media (prefers-reduced-motion: reduce) { .cc-ve > summary i { transition-duration: 0.001ms; } }

.cc-may.cc-app { display: grid; grid-template-columns: 340px minmax(0, 1fr); padding: 0; align-items: start; }
.cc-app__vao { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 24px; padding: 28px 24px; min-width: 0; }
.cc-app__ra { align-self: stretch; min-width: 0; min-height: 480px; padding: 28px 32px 32px; border-left: 1px solid var(--hairline); }
@media (max-width: 980px) {
  .cc-may.cc-app { grid-template-columns: minmax(0, 1fr); }
  .cc-app__vao { position: static; }
  .cc-app__ra { min-height: 0; border-left: 0; border-top: 1px solid var(--hairline); }
}
@media (max-width: 640px) { .cc-may.cc-app { padding: 0; } .cc-app__vao { padding: 20px 16px; gap: 20px; } .cc-app__ra { padding: 20px 16px 24px; } }

.cc-vao { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.cc-vao + .cc-vao { padding-top: 24px; border-top: 1px solid var(--hairline); }
.cc-vao__nhan { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--text-primary); }
.cc-vao__so { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; flex: none;
  background: var(--color-deep-navy); color: var(--color-off-white); }
.cc-app .cc-chon--doi, .cc-app .cc-chon--luoi { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cc-app .cc-chon--doi button { justify-content: center; }
.cc-app .cc-chon--luoi button { padding: 8px 12px; font-size: 14px; line-height: 1.3; justify-content: flex-start; text-align: left; }
.cc-app .cc-dc-nhanh button { min-height: 44px; padding: 0 12px; }
.cc-app .cc-tha { min-height: 148px; }
.cc-o-don { display: flex; align-items: center; gap: 10px; color: var(--text-secondary); font-size: 15px; }
.cc-o-don .cc-o { max-width: 128px; }
.cc-o-don[hidden] { display: none; }  /* display:flex ở trên đè thuộc tính ẩn: ô chỉ của một kiểu (vd màng co) từng hiện ở mọi kiểu */
/* nhãn đứng trên ô, cùng nhịp các mục khác của bảng nhập (logo-chu: Độ đậm) */
.cc-o-don--doc { flex-direction: column; align-items: flex-start; gap: 6px; font-size: 14px; font-weight: 600; color: var(--text-primary); }
.cc-o-don--doc .cc-o { max-width: 200px; }
.cc-mau-nut { margin-top: 8px; }
.cc-mau-nut i { font-size: 18px; }

.cc-tep { display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 14px; border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md); background: var(--surface-page); }
.cc-tep > i { font-size: 22px; color: var(--text-brand); flex: none; }
.cc-tep__ten { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.cc-tep__ten b { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-tep__ten span { font-size: 12px; color: var(--text-secondary); }
.cc-tep__doi { flex: none; min-height: 44px; padding: 0 8px; background: none; border: 0; cursor: pointer; font: 600 14px var(--font-sans); color: var(--text-brand); }
.cc-tep__doi:hover { text-decoration: underline; text-underline-offset: 3px; }
.cc-tep__doi:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }

.cc-trong { min-height: 416px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center;
  padding: 40px 32px; border: 1.5px dashed var(--border-subtle); border-radius: var(--radius-lg); background: var(--surface-page); }
.cc-trong__ic { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-paper); color: var(--text-brand); font-size: 30px; }
.cc-trong__tieu { margin: 4px 0 0; font-family: var(--font-heading); font-weight: 600; font-size: 22px; line-height: 1.25; color: var(--text-primary); }
.cc-trong__loi { margin: 0; max-width: 440px; font-size: 15px; line-height: 1.6; color: var(--text-secondary); }
.cc-trong__ds { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 16px; font-size: 13px; color: var(--text-secondary); }
.cc-trong__ds li { display: inline-flex; align-items: center; gap: 6px; }
.cc-trong__ds i { color: var(--color-success); }
@media (max-width: 980px) { .cc-trong { min-height: 0; padding: 32px 20px; } }
/* Màn hẹp: nút xem mẫu lên ngay dưới lời mở (trước ảnh ví dụ, danh sách), thêm dòng "Chưa có tệp?" dưới ô thả */
.cc-tha__mau { display: none; }
/* Vòng 2 (26/10): màn rộng cũng đưa nút mẫu lên trước ảnh ví dụ (kiem-tep-in 1440 từng nằm ở 927px, ngoài màn 900) */
.cc-trong__ic, .cc-trong__tieu, .cc-trong__loi { order: -2; }
.cc-trong .cc-mau-nut { order: -1; }
@media (max-width: 980px) {
  .cc-tha__mau { display: inline-flex; }
  .cc-tha[hidden] + .cc-tha__mau, .cc-app:has(.cc-kq:not([hidden])) .cc-tha__mau { display: none; }
}
/* Cặp ảnh trước / sau ở vùng kết quả lúc trống (20/10/2026): khách thấy công cụ sửa được gì trên vật thật */
.cc-trong--vd { justify-content: flex-start; padding: 32px 24px; }
.cc-vd { width: 100%; max-width: 560px; margin: 4px 0 0; }
.cc-vd__tieu { margin: 0 0 12px; font-size: 13px; font-weight: 600; letter-spacing: var(--tracking-wide); color: var(--text-secondary); }
.cc-vd__cap { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cc-vd__o { margin: 0; display: flex; flex-direction: column; gap: 8px; text-align: left; min-width: 0; }
.cc-vd__o img { width: 100%; height: auto; display: block; border-radius: var(--radius-md); border: 1px solid var(--border-subtle); background: var(--surface-card); }
.cc-vd__o figcaption { font-size: 13px; line-height: 1.5; color: var(--text-secondary); }
.cc-vd__nhan { display: inline-flex; align-items: center; gap: 6px; margin-right: 6px; font-weight: 600; color: var(--text-primary); }
.cc-vd__nhan::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--color-warning); }
.cc-vd__o--sau .cc-vd__nhan::before { background: var(--color-success); }
@media (max-width: 640px) { .cc-trong--vd { padding: 24px 16px; } .cc-vd__cap { gap: 8px; } .cc-vd__o figcaption { font-size: 12px; } }
.cc-ket { padding: 20px 24px; border: 1px solid var(--border-subtle); border-left: 4px solid var(--color-success); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-ket[data-muc="vua"] { border-left-color: var(--color-warning); }
.cc-ket[data-muc="yeu"] { border-left-color: var(--color-danger); }
.cc-ket__dau { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.cc-ket__muc { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-heading); font-weight: 600; font-size: 24px; line-height: 1.2; color: var(--text-status-success); }
.cc-ket[data-muc="vua"] .cc-ket__muc { color: var(--text-status-warning); }
.cc-ket[data-muc="yeu"] .cc-ket__muc { color: var(--text-status-critical); }
.cc-ket__dot { width: 12px; height: 12px; border-radius: 50%; background: currentColor; }
.cc-ket__nhan { display: flex; flex-wrap: wrap; gap: 6px; }
.cc-ket__nhan span { font-size: 12px; padding: 4px 10px; border-radius: var(--radius-sm); background: var(--surface-page); border: 1px solid var(--hairline); color: var(--text-secondary); }
.cc-app .cc-ket__cau { margin: 8px 0 16px; color: var(--text-primary); }
/* ba ô đếm chia đều một hàng (soát 21/10, việc 17: ô rộng hẹp theo chữ, có công cụ rớt ô thứ ba xuống dòng) */
.cc-ket__dem { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.cc-ket__dem li { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; line-height: 1.3; font-size: 13px; padding: 6px 8px; border-radius: var(--radius-sm); background: var(--surface-page); color: var(--text-secondary); }
.cc-ket__dem b { font-variant-numeric: tabular-nums; font-size: 15px; color: var(--text-status-success); }
.cc-ket__dem li[data-muc="vua"] b { color: var(--text-status-warning); }
.cc-ket__dem li[data-muc="yeu"] b { color: var(--text-status-critical); }
@media (max-width: 640px) { .cc-ket { padding: 16px; } .cc-ket__muc { font-size: 20px; } }
/* Dải kết quả dính đáy (23/10/2026, cong-cu.js): màn ≤980, đầu kết quả khuất thì mức kết luận đứng ở đáy màn */
.cc-dai { position: fixed; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); z-index: var(--z-sticky);
  display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 6px 6px 6px 16px;
  border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); box-shadow: var(--shadow-md);
  opacity: 0; transform: translateY(12px); visibility: hidden;
  transition: opacity var(--dur-base) var(--ease-out), transform var(--dur-base) var(--ease-out), visibility 0s linear var(--dur-base); }
.cc-dai--hien { opacity: 1; transform: none; visibility: visible; transition-delay: 0s; }
.cc-dai__muc { display: inline-flex; align-items: center; gap: 8px; min-width: 0; font-family: var(--font-heading); font-weight: 600; font-size: 17px; line-height: 1.2; color: var(--text-primary); }
.cc-dai[data-muc="tot"] .cc-dai__muc { color: var(--text-status-success); }
.cc-dai[data-muc="vua"] .cc-dai__muc { color: var(--text-status-warning); }
.cc-dai[data-muc="yeu"] .cc-dai__muc { color: var(--text-status-critical); }
.cc-dai:not([data-muc="tot"]):not([data-muc="vua"]):not([data-muc="yeu"]) .cc-ket__dot { background: var(--text-brand); }
.cc-dai__chu { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cc-dai__nut { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border: 0; border-radius: var(--radius-sm);
  background: var(--color-deep-navy); color: var(--color-off-white); font: 600 14px var(--font-sans); cursor: pointer; }
.cc-dai__nut:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-dai--co-hinh { justify-content: flex-start; padding-left: 6px; }
.cc-dai--co-hinh .cc-dai__nut { margin-left: auto; }
.cc-dai__hinh { flex: none; display: inline-flex; align-items: center; justify-content: center; height: 56px; min-width: 56px; max-width: 88px; padding: 4px;
  border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); background: var(--surface-card); cursor: pointer; }
.cc-dai__hinh img { display: block; height: 100%; width: auto; max-width: 78px; object-fit: contain; }
.cc-dai__hinh[hidden] { display: none; }
.cc-dai__hinh:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-dai--doi { animation: cc-dai-doi var(--dur-slow) var(--ease-out); }
@keyframes cc-dai-doi { from { background: var(--surface-paper); border-color: var(--border-strong); } to { background: var(--surface-card); border-color: var(--border-subtle); } }
@media (min-width: 981px) { .cc-dai { display: none; } }
@media (prefers-reduced-motion: reduce) { .cc-dai { transition: none; transform: none; } .cc-dai--doi { animation: none; } }
.cc-app .cc-khungs, .cc-app .cc-in-the { margin-top: 20px; }
.cc-kq__h3 { font-family: var(--font-heading); font-weight: 600; font-size: 18px; line-height: 1.3; margin: 32px 0 0; color: var(--text-primary); }
.cc-kq__h3 + .cc-soi { margin-top: 12px; }

/* bản đồ điểm chạm trong vùng kết quả: năm chặng là một hàng dọc gập được, chỉ chặng khách bỏ đi mở sẵn */
.cc-app .cc-kq__h { font-size: 26px; }
.cc-app .cc-dc-changs { grid-template-columns: minmax(0, 1fr); gap: 8px; }
.cc-app .cc-dc-chang { padding: 0; }
.cc-app .cc-dc-chang summary { min-height: 56px; padding: 12px 16px; cursor: pointer; pointer-events: auto; grid-template-columns: 28px minmax(0, 1fr) auto; align-items: center; }
.cc-app .cc-dc-chang summary .cc-dc-chang__nhan { grid-column: 2 / 3; grid-row: 2; }
.cc-app .cc-dc-chang__mo { display: inline-block; grid-column: 3; grid-row: 1 / 3; }
.cc-app .cc-dc-chang details > :not(summary) { margin: 10px 20px 0 54px; }
.cc-app .cc-dc-chang details > summary + * { margin-top: 0; }
.cc-app .cc-dc-chang details > :last-child { margin-bottom: 18px; }
@media (max-width: 640px) { .cc-app .cc-dc-chang details > :not(summary) { margin-left: 16px; margin-right: 16px; } }
.cc-app .cc-dc-chang:not([data-roi]):hover { border-color: var(--border-strong); }

/* ================= công cụ: soi bảng màu (cc-sm-, 20/10/2026) =================
   Màu của khách là NỘI DUNG (style nội tuyến từ dữ liệu khách nhập), khung giữ token của hệ. */
.cc-sm-ds { display: flex; flex-direction: column; gap: 8px; }
.cc-sm-dong { display: grid; grid-template-columns: 44px minmax(0, 1fr) 44px; gap: 8px; align-items: end; }
.cc-sm-pick { width: 44px; height: 44px; padding: 0; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: none; cursor: pointer; }
.cc-sm-pick::-webkit-color-swatch-wrapper { padding: 3px; }
.cc-sm-pick::-webkit-color-swatch { border: 0; border-radius: 4px; }
.cc-sm-vai { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 600; color: var(--text-secondary); min-width: 0; }
.cc-sm-hex { max-width: none; font-family: var(--font-mono); text-transform: uppercase; }
.cc-sm-hex::placeholder { text-transform: none; font-family: var(--font-sans); }
.cc-sm-hex[aria-invalid="true"] { border-color: var(--color-danger); }
.cc-sm-xoa { width: 44px; height: 44px; border: 0; background: none; color: var(--text-secondary); cursor: pointer; border-radius: var(--radius-sm); font-size: 18px; }
.cc-sm-xoa:hover { color: var(--text-primary); background: var(--surface-page); }
.cc-sm-xoa:focus-visible, .cc-sm-pick:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-app .cc-sm-tha { min-height: 104px; }
.cc-sm-nganh { max-width: none; }
.cc-sm-o { display: inline-block; width: 28px; height: 28px; border-radius: var(--radius-sm); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text-primary) 12%, transparent); flex: none; }
.cc-sm-o--nho { width: 16px; height: 16px; border-radius: 4px; }
.cc-sm-dai { list-style: none; margin: 12px 0 8px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 12px; }
.cc-sm-dai li { display: flex; flex-direction: column; gap: 2px; font-size: 13px; color: var(--text-secondary); min-width: 0; }
.cc-sm-dai b { color: var(--text-primary); font-size: 14px; margin-top: 8px; }
.cc-sm-dai__o { display: grid; grid-template-columns: 1fr 1fr; height: 72px; border-radius: var(--radius-md); overflow: hidden;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text-primary) 12%, transparent); }
.cc-sm-dai__ma { font-family: var(--font-mono); font-size: 12px; }
.cc-sm-dai__in { display: inline-flex; align-items: center; gap: 4px; color: var(--text-status-warning); font-weight: 600; font-size: 12px; }
.cc-sm-bang { overflow-x: auto; margin-top: 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); }
.cc-sm-bang table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 520px; }
.cc-sm-bang th, .cc-sm-bang td { padding: 10px 12px; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--hairline); }
.cc-sm-bang tr:last-child th, .cc-sm-bang tr:last-child td { border-bottom: 0; }
.cc-sm-bang thead th { font-weight: 600; color: var(--text-secondary); background: var(--surface-page); font-size: 12px; }
.cc-sm-bang tbody th { font-weight: 600; white-space: nowrap; }
.cc-sm-bang tbody th .cc-sm-o { margin-right: 8px; vertical-align: -3px; }
.cc-sm-bang td { white-space: nowrap; }
.cc-sm-aa { display: inline-grid; place-items: center; width: 40px; height: 32px; border-radius: var(--radius-sm); font: 600 15px var(--font-sans); margin-right: 8px; vertical-align: middle;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text-primary) 10%, transparent); }
.cc-sm-tp { display: inline-flex; flex-direction: column; vertical-align: middle; line-height: 1.3; }
.cc-sm-tp b { font-variant-numeric: tabular-nums; color: var(--text-primary); }
.cc-sm-tp span { font-size: 12px; color: var(--text-status-success); }
.cc-sm-bang td[data-muc="vua"] .cc-sm-tp span { color: var(--text-status-warning); }
.cc-sm-bang td[data-muc="yeu"] .cc-sm-tp span { color: var(--text-status-critical); }
.cc-sm-tp__ten { display: block; font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.cc-sm-mu { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.cc-sm-mu li { display: grid; grid-template-columns: 184px minmax(0, 1fr); gap: 12px; align-items: center; font-size: 13px; color: var(--text-secondary); }
.cc-sm-mu__dai { display: flex; height: 36px; border-radius: var(--radius-sm); overflow: hidden; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text-primary) 10%, transparent); }
.cc-sm-mu__dai .cc-sm-o { flex: 1; width: auto; height: auto; border-radius: 0; box-shadow: none; }
@media (max-width: 640px) { .cc-sm-mu li { grid-template-columns: minmax(0, 1fr); gap: 4px; } }
/* điện thoại: bảng tương phản thành thẻ, mỗi màu nền một thẻ, ba ô chữ xếp ngang (không vuốt ngang) */
@media (max-width: 640px) {
  .cc-sm-bang { overflow: visible; border: 0; display: block; }
  .cc-sm-bang table { min-width: 0; display: block; }
  .cc-sm-bang thead { display: none; }
  .cc-sm-bang tbody { display: grid; gap: 8px; }
  .cc-sm-bang tr { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 6px; padding: 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); }
  .cc-sm-bang th, .cc-sm-bang td { padding: 0; border: 0; white-space: normal; }
  .cc-sm-bang tbody th { grid-column: 1 / -1; }
  .cc-sm-bang td { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
  .cc-sm-bang td::before { content: attr(data-nhan); font-size: 11px; color: var(--text-secondary); }
  .cc-sm-bang td.cc-sm-trong { display: none; }
  .cc-sm-aa { margin-right: 0; }
}

/* ================= công cụ: mã QR theo thương hiệu (cc-qr-, 20/10/2026) ================= */
.cc-qr-chu { display: flex; flex-direction: column; gap: 12px; }
.cc-qr-nhan { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--text-secondary); }
.cc-qr-o { max-width: none; font-weight: 400; }
textarea.cc-qr-o { padding: 10px 12px; min-height: 88px; resize: vertical; line-height: 1.5; }
.cc-qr-maus { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.cc-qr-mau { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; align-items: end; }
.cc-app .cc-qr-kieu { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cc-app .cc-qr-kieu button { padding: 0 8px; font-size: 13px; }
.cc-qr-logo { display: flex; flex-direction: column; gap: 12px; }
.cc-qr-logo[hidden] { display: none; }
.cc-qr-thanh { width: 100%; accent-color: var(--brand); min-height: 32px; }
.cc-qr-soco { font-variant-numeric: tabular-nums; color: var(--text-primary); }
.cc-qr-hop { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-size: 14px; cursor: pointer; }
.cc-qr-hop input { width: 18px; height: 18px; accent-color: var(--brand); }
.cc-qr-cos { display: flex; flex-direction: column; gap: 8px; }
.cc-qr-so__nhan { flex: 1; min-width: 0; font-size: 14px; }
.cc-qr-so .cc-o { max-width: 88px; text-align: right; }
.cc-qr-xem { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: 24px; margin-top: 20px; align-items: start; }
@media (max-width: 720px) { .cc-qr-xem { grid-template-columns: minmax(0, 1fr); } }
.cc-qr-khung { margin: 0; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-page); }
.cc-qr-anh { display: block; width: 100%; height: auto; border-radius: var(--radius-sm); }
.cc-qr-khung figcaption { margin-top: 8px; font-size: 12px; color: var(--text-secondary); word-break: break-all; }
.cc-qr-ben { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.cc-qr-to { padding: 24px; border-radius: var(--radius-md); background: var(--surface-paper); border: 1px solid var(--hairline); display: flex; align-items: center; justify-content: center; }
.cc-qr-anh--nho { width: 72px; height: 72px; image-rendering: auto; }
.cc-qr-tai { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }

/* ================= công cụ: mã vạch bán lẻ (cc-mv-, 22/10/2026) ================= */
.cc-app .cc-mv-loai button { min-height: 56px; align-items: center; gap: 10px; }
.cc-mv-loai button > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.cc-mv-loai b { font-weight: 600; color: var(--text-primary); }
.cc-mv-loai small { font-size: 12px; color: var(--text-secondary); font-weight: 400; }
.cc-mv-loai button[aria-pressed="true"] b { color: var(--text-brand); }
.cc-mv-xem { display: flex; flex-direction: column; gap: 12px; margin-top: 20px; }
.cc-mv-khung { display: flex; flex-direction: column; align-items: center; padding: 24px; }
.cc-mv-anh { display: block; width: 100%; max-width: 360px; height: auto; }
.cc-mv-khung figcaption { text-align: center; word-break: normal; }
.cc-mv-chua { display: flex; gap: 10px; align-items: flex-start; margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-primary); }
.cc-mv-chua i { color: var(--color-danger); font-size: 20px; flex: none; margin-top: 2px; }
/* nhiều mã ra tờ tem: các khối bật tắt theo chế độ khai display nên phải tự ẩn khi mang [hidden] */
.cc-qr-chu[hidden], .cc-qr-cos[hidden], .cc-vao[hidden], .cc-trong[hidden], .cc-mv-dang[hidden] { display: none; }
.cc-app .cc-mv-che button { gap: 8px; }
textarea.cc-mv-ds { min-height: 168px; font: 16px/1.5 var(--font-mono); white-space: pre; overflow-x: auto; }
.cc-mv-dsl { margin: 0 0 12px; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; font-size: 14px; line-height: 1.5; }
.cc-mv-dsl code { font: 13px/1.5 var(--font-mono); overflow-wrap: anywhere; }
.cc-mv-dang { margin: 0 0 12px; font-variant-numeric: tabular-nums; }
.cc-mv-to { position: relative; width: 100%; max-width: 420px; background: var(--surface-card); border: 1px solid var(--border-strong); border-radius: var(--radius-sm); overflow: hidden; }
.cc-mv-to--cuon { max-width: 240px; }
.cc-mv-o { position: absolute; display: flex; align-items: center; justify-content: center; outline: 1px dashed var(--border-subtle); outline-offset: -1px; }
.cc-mv-o img { display: block; height: auto; }

/* ================= công cụ: cắt ảnh đúng khổ (cc-ca-, 20/10/2026) ================= */
.cc-ca-goc { display: flex; flex-direction: column; gap: 8px; }
.cc-ca-goc[hidden] { display: none; }
.cc-ca-goc__o { position: relative; cursor: crosshair; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--border-subtle); line-height: 0; }
.cc-ca-goc__anh { width: 100%; height: auto; display: block; }
.cc-ca-diem { position: absolute; width: 20px; height: 20px; margin: -10px 0 0 -10px; border-radius: 50%; border: 3px solid var(--color-white);
  background: var(--color-signal-red); box-shadow: 0 0 0 1px color-mix(in srgb, var(--color-deep-navy) 40%, transparent); pointer-events: none; }
.cc-ca-khos { display: flex; flex-direction: column; gap: 4px; }
.cc-ca-nhom { margin: 8px 0 0; font-size: 12px; font-weight: 600; letter-spacing: 0.04em; color: var(--text-secondary); }
.cc-ca-nhom:first-child { margin-top: 0; }
.cc-ca-kho { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; min-height: 44px; cursor: pointer; }
.cc-ca-kho input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--brand); flex: none; }
.cc-ca-kho > span { display: flex; flex-direction: column; font-size: 12px; color: var(--text-secondary); line-height: 1.4; }
.cc-ca-kho b { font-size: 14px; color: var(--text-primary); font-weight: 600; }
.cc-ca-luoi { list-style: none; margin: 20px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; align-items: start; }
.cc-ca-luoi li { border: 1px solid var(--border-subtle); border-radius: var(--radius-md); overflow: hidden; background: var(--surface-card); min-width: 0; }
.cc-ca-hinh { position: relative; background: var(--surface-page); overflow: hidden; }
.cc-ca-hinh img { display: block; width: 100%; height: 100%; object-fit: cover; }
.cc-ca-che { position: absolute; left: 0; right: 0; background: color-mix(in srgb, var(--color-deep-navy) 45%, transparent); }
.cc-ca-che--tren { top: 0; } .cc-ca-che--duoi { bottom: 0; }
.cc-ca-the { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 2px; font-size: 12px; color: var(--text-secondary); }
.cc-ca-the b { font-size: 14px; color: var(--text-primary); }
.cc-ca-so { font-variant-numeric: tabular-nums; }
/* QC 26/10: điện thoại bày lưới khổ ảnh hai cột (một cột làm màn Kết quả dài 9 màn) */
@media (max-width: 640px) {
  .cc-app .cc-ca-luoi { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .cc-app .cc-ca-the { padding: 8px 10px 10px; }
}
/* chia mã: nút mở hết danh sách sản phẩm ở điện thoại */
.cc-chm-ds > li[hidden] { display: none; }
.cc-chm-het { border: 0; background: none; padding: 0 16px; cursor: pointer; font: inherit; font-weight: 600; }
.cc-ca-luoi li[data-nho] .cc-ca-so { color: var(--text-status-warning); }
.cc-ca-tai { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; min-height: 36px; color: var(--text-brand); font-weight: 600; font-size: 13px; text-decoration: none; }
.cc-ca-tai:hover { text-decoration: underline; text-underline-offset: 3px; }
.cc-ca-canh { display: inline-flex; align-items: center; gap: 4px; color: var(--text-status-warning); font-weight: 600; font-size: 12px; }

/* ================= công cụ: xuất trọn bộ logo (cc-bl-, 20/10/2026) ================= */
.cc-bl-xem { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
@media (max-width: 720px) { .cc-bl-xem { grid-template-columns: minmax(0, 1fr); } }
.cc-bl-xem figure { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.cc-bl-xem figcaption { font-size: 12px; color: var(--text-secondary); }
.cc-bl-tab { display: flex; align-items: center; gap: 8px; height: 88px; padding: 0 16px; border-radius: var(--radius-md); background: var(--color-soft-gray, var(--surface-sunken)); font-size: 13px; }
.cc-bl-tab > span { flex: 1; min-width: 0; padding: 8px 10px; border-radius: 8px 8px 0 0; background: var(--surface-card); display: flex; gap: 8px; align-items: center; }
.cc-bl-tab img { width: 16px; height: 16px; flex: none; }
.cc-bl-tab i { font-size: 12px; color: var(--text-secondary); }
.cc-bl-tab { position: relative; }
.cc-bl-tab img { position: absolute; left: 26px; }
.cc-bl-tab > span { padding-left: 34px; }
.cc-bl-dd, .cc-bl-toi { height: 88px; border-radius: var(--radius-md); display: grid; place-items: center; }
.cc-bl-dd { background: var(--surface-page); border: 1px solid var(--border-subtle); }
.cc-bl-dd img { width: 72px; height: 72px; }
.cc-bl-toi { background: var(--color-deep-navy); }
.cc-bl-toi img { width: 160px; height: auto; }
.cc-bl-ds { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.cc-bl-ds li { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 8px 12px 8px 8px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); }
.cc-bl-o { width: 56px; height: 56px; border-radius: var(--radius-sm); display: grid; place-items: center; padding: 6px;
  background-color: var(--surface-page); background-image: linear-gradient(45deg, var(--hairline) 25%, transparent 25%, transparent 75%, var(--hairline) 75%), linear-gradient(45deg, var(--hairline) 25%, transparent 25%, transparent 75%, var(--hairline) 75%);
  background-size: 12px 12px; background-position: 0 0, 6px 6px; }
.cc-bl-o--toi { background: var(--color-deep-navy); }
.cc-bl-o img { max-width: 100%; max-height: 100%; }
.cc-bl-ten { display: flex; flex-direction: column; min-width: 0; font-size: 12px; color: var(--text-secondary); line-height: 1.45; }
.cc-bl-ten b { font-size: 14px; color: var(--text-primary); }
.cc-bl-ten span { overflow-wrap: anywhere; }

/* ================= công cụ: thử font tiếng Việt (cc-tf-, 20/10/2026) ================= */
.cc-tf-cau { display: flex; flex-wrap: wrap; gap: 0 16px; }
.cc-tf-mau { margin: 12px 0 0; padding: 16px 20px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); overflow: hidden; }
.cc-tf-mau p { margin: 0; color: var(--text-primary); overflow-wrap: anywhere; }
.cc-tf-mau figcaption { margin-top: 8px; font-size: 12px; color: var(--text-secondary); }
.cc-tf-bang { list-style: none; margin: 16px 0 8px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 4px; }
.cc-tf-bang li { height: 48px; display: grid; place-items: center; font-size: 24px; border-radius: var(--radius-sm); background: var(--surface-page); color: var(--text-primary); }
.cc-tf-bang li[data-thieu] { color: var(--text-status-critical); background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--color-danger) 10%, transparent) 0 6px, transparent 6px 12px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-danger) 40%, transparent); }

/* ================= công cụ: thử logo chữ có dấu (cc-lc-, 20/10/2026) ================= */
.cc-lc-ngat { display: flex; flex-direction: column; }
.cc-app .cc-lc-ngat button { justify-content: flex-start; min-height: 44px; font-size: 14px; font-weight: 500; }
.cc-lc-xem { margin-top: 20px; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); overflow-x: auto; }
.cc-lc-khung { display: block; max-width: 100%; height: auto; margin: 0 auto; }
.cc-lc-chu { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 12px; color: var(--text-secondary); }
.cc-lc-chu li { display: inline-flex; align-items: center; gap: 8px; }
.cc-lc-chu span { width: 24px; height: 0; border-top: 2px dashed var(--text-secondary); }
.cc-lc-chu .cc-lc-lien { border-top: 2px solid var(--color-signal-red); }
.cc-lc-chu .cc-lc-cham { border-top: 2px dotted color-mix(in srgb, var(--color-signal-red) 50%, transparent); }
.cc-lc-ban { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
@media (max-width: 720px) { .cc-lc-ban { grid-template-columns: minmax(0, 1fr); } }
.cc-lc-ban figure { margin: 0; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); display: flex; flex-direction: column; justify-content: space-between; gap: 8px; min-width: 0; }
.cc-lc-ban p { margin: 0; color: var(--color-deep-navy); line-height: 1.3; overflow-wrap: anywhere; }
.cc-lc-ban figcaption { font-size: 12px; color: var(--text-secondary); }
.cc-lc-slug { font-family: var(--font-mono); font-size: 15px; }

/* ================= công cụ: soi tên thương hiệu (cc-st-, 20/10/2026) ================= */
.cc-st-ban { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
@media (max-width: 1080px) { .cc-st-ban { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.cc-st-ban figure { margin: 0; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); display: flex; flex-direction: column; justify-content: space-between; gap: 8px; min-width: 0; }
.cc-st-ban figcaption { font-size: 12px; color: var(--text-secondary); }
.cc-st-ten { margin: 0; font-family: var(--font-heading); font-weight: 600; font-size: 22px; line-height: 1.25; color: var(--text-primary); overflow-wrap: anywhere; }
.cc-st-ma { margin: 0; font-family: var(--font-mono); font-size: 15px; overflow-wrap: anywhere; }
.cc-st-nham { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.cc-st-nham li { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 12px; padding: 10px 14px; border-radius: var(--radius-sm); background: var(--surface-page); font-size: 14px; }
.cc-st-nham b { font-weight: 600; }
.cc-st-nham span { color: var(--text-secondary); }
.cc-st-lien { list-style: none; margin: 16px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 720px) { .cc-st-lien { grid-template-columns: minmax(0, 1fr); } }
.cc-st-lien a { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 8px; padding: 12px 14px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); text-decoration: none; color: var(--text-primary); }
.cc-st-lien a:hover { border-color: var(--border-strong); }
.cc-st-lien b { font-size: 14px; }
.cc-st-lien span { grid-column: 1; font-size: 12px; color: var(--text-secondary); }
.cc-st-lien i { grid-row: 1 / 3; grid-column: 2; align-self: center; color: var(--text-brand); }

/* ================= công cụ: dựng khuôn hộp (cc-kh-, 20/10/2026) ================= */
.cc-kh-giay { max-width: none; }
.cc-kh-xem { margin-top: 20px; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-page); }
.cc-kh-xem svg { display: block; width: 100%; height: auto; max-height: 560px; }
.cc-lc-chu .cc-kh-cat { border-top: 2px solid var(--color-signal-red); }
.cc-lc-chu .cc-kh-gap { border-top-color: var(--color-studio-blue); }
.cc-lc-chu .cc-kh-tran { border-top: 6px solid var(--hairline); }

/* ================= công cụ: nhãn chai lọ hình trụ (cc-nc-, 22/10/2026) ================= */
.cc-nc-xem { display: grid; grid-template-columns: minmax(0, 1fr) 128px; gap: 16px; align-items: center; }
.cc-nc-tren { margin: 0; }
.cc-nc-tren svg { max-height: 150px; }
.cc-nc-tren figcaption { margin-top: 8px; font-size: 12px; line-height: 1.4; color: var(--text-secondary); text-align: center; }
.cc-lc-chu .cc-nc-doc { height: 8px; border-top: 0; background: color-mix(in srgb, var(--color-studio-blue) 22%, transparent); }
.cc-lc-chu .cc-nc-chong { height: 8px; border-top: 0; background: color-mix(in srgb, var(--color-bordeaux) 28%, transparent); }
.cc-nc-cuon { margin-top: 14px; display: grid; gap: 6px; }
.cc-nc-cuon .cc-o { max-width: none; flex: 1; min-width: 0; }
.cc-nc-ct { margin-top: 20px; }
.cc-nc-ct dl { margin: 8px 0 0; display: grid; gap: 4px; }
.cc-nc-ct dl > div { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 12px; padding: 8px 12px; border-radius: var(--radius-sm); background: var(--surface-page); font-size: 14px; }
.cc-nc-ct dt { color: var(--text-secondary); }
.cc-nc-ct dd { margin: 0; color: var(--text-primary); font-variant-numeric: tabular-nums; }
/* xem nhãn quấn trên chai (chặng 2, 22/10/2026): trái hình chai, phải ô tải ảnh + góc xoay */
.cc-nc-quan { margin-top: 24px; }
/* ô số đủ chỗ cho chữ gợi ý "Bằng thân", "Tự tính" (23/10/2026) */
.cc-may[data-cong-cu="nhan-chai"] .cc-qr-so .cc-o { max-width: 104px; }
.cc-nc-quan__ban { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; margin-top: 12px;
  padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-page); }
.cc-nc-quan__hinh { display: flex; justify-content: center; align-items: center; min-height: 240px; }
.cc-nc-chai { display: block; max-width: 100%; cursor: grab; touch-action: pan-y; }
.cc-nc-chai:active { cursor: grabbing; }
.cc-nc-quan__ben { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; align-content: start; min-width: 0; }
.cc-nc-quan__ben > .sv-btn { justify-self: start; }
.cc-nc-quan__ben > [hidden] { display: none; }
.cc-nc-dk { display: grid; gap: 12px; }
.cc-nc-dk .cc-chon button { padding: 0 14px; }
.cc-nc-dk__doc { display: flex; align-items: center; gap: 8px; min-height: 44px; font-size: 14px; cursor: pointer; }
.cc-nc-dk__doc input { width: 18px; height: 18px; accent-color: var(--brand); }
.cc-nc-quan__ben .cc-goi-y[data-muc="vua"], .cc-nc-quan__ben .cc-goi-y[data-muc="yeu"] { color: var(--text-status-warning); }
.cc-nc-quan__ben .cc-goi-y[data-muc="yeu"] { color: var(--text-status-critical); }
.cc-kh-3d { position: relative; width: 100%; display: flex; align-items: center; justify-content: center; perspective: 1100px;
  cursor: grab; touch-action: pan-y; user-select: none; }
.cc-kh-3d[data-keo] { cursor: grabbing; }
.cc-kh-3d__hop { position: relative; transform-style: preserve-3d; transition: transform 480ms cubic-bezier(.16, 1, .3, 1); }
.cc-kh-3d[data-keo] .cc-kh-3d__hop { transition: none; }
.cc-kh-3d__mat { position: absolute; display: flex; align-items: center; justify-content: center; overflow: hidden; backface-visibility: hidden;
  background: var(--surface-card) center / 100% 100% no-repeat; border: 1px solid var(--border-strong); }
.cc-kh-3d__mat span { padding: 4px; font-size: 12px; color: var(--text-secondary); text-align: center; }
.cc-kh-3d__mat::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: var(--color-deep-navy); opacity: 0; }
.cc-kh-3d__mat[data-mat="phai"]::after, .cc-kh-3d__mat[data-mat="trai"]::after { opacity: .14; }
.cc-kh-3d__mat[data-mat="sau"]::after, .cc-kh-3d__mat[data-mat="day"]::after { opacity: .2; }
.cc-kh-3d__nap { position: absolute; top: 0; left: 0; right: 0; border-bottom: 1px solid var(--color-deep-navy); opacity: .45; }
.cc-kh-o { display: grid; gap: 8px; }
.cc-kh-o__dong { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 4px 8px; padding: 8px 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); background: var(--surface-card); }
.cc-kh-o__dong[data-lech] { border-color: var(--color-warning); }
.cc-kh-o__ten { display: flex; flex-direction: column; min-width: 0; }
.cc-kh-o__ten b { font-size: 14px; font-weight: 600; }
.cc-kh-o__ten span { font-size: 12px; color: var(--text-secondary); }
.cc-kh-o__dong[data-lech] .cc-kh-o__ten span { color: var(--text-status-warning); }
.cc-kh-o__chon { position: relative; cursor: pointer; }
.cc-kh-o__chon input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.cc-kh-o__chon:focus-within { box-shadow: var(--ring); }
@media (max-width: 640px) { .cc-kh-o__dong { grid-template-columns: minmax(0, 1fr) auto; } .cc-kh-o__ten { grid-column: 1 / -1; } }
@media (prefers-reduced-motion: reduce) { .cc-kh-3d__hop { transition-duration: 0.001ms; } }
@media (max-width: 640px) {
  .cc-nc-xem { grid-template-columns: 1fr; }
  .cc-nc-tren { justify-self: center; width: 128px; }
  .cc-nc-ct dl > div { grid-template-columns: 1fr; gap: 2px; }
  .cc-nc-quan__ban { grid-template-columns: 1fr; }
}

/* ================= công cụ: lịch lùi từ ngày ra mắt (cc-ll-, 20/10/2026) ================= */
.cc-ll-ngay { max-width: none; }
/* Lịch đọc được (28/10/2026): ô ngày nói ngay có kịp không + gợi ý ngày; biểu đồ có thước tháng, vạch Hôm nay · Ra mắt,
   thanh chia đoạn, móc nối việc phải chờ, dải Tết · mùa ngành; màn hẹp mặc định xem theo tuần (lich-lui.js veBieuDo · veTuan) */
.cc-ll-ghi[data-muc="yeu"] { color: var(--text-status-critical); }
.cc-ll-ghi[data-muc="vua"] { color: var(--text-status-warning); }
.cc-ll-ghi[data-muc="tot"] { color: var(--text-status-success); }
.cc-ll-goi { display: grid; gap: 8px; margin-top: 8px; }
.cc-ll-goi button { width: 100%; min-height: 44px; padding: 6px 12px; gap: 6px; font-size: 13px; line-height: 1.3; text-align: left; }
.cc-ll-goi button span { margin-left: auto; padding-left: 4px; font-weight: 400; color: var(--text-secondary); font-variant-numeric: tabular-nums; white-space: nowrap; }
.cc-ll-tom { text-wrap: pretty; display: flex; gap: 10px; align-items: flex-start; margin: 0 0 12px; padding: 12px 16px; border: 1px solid var(--border-subtle); border-left: 3px solid var(--color-success); border-radius: var(--radius-md); font-size: 15px; line-height: 1.55; color: var(--text-primary); }
.cc-ll-tom > i { flex: none; margin-top: 3px; font-size: 18px; color: var(--text-status-success); }
.cc-ll-tom[data-muc="vua"] { border-left-color: var(--color-warning); }
.cc-ll-tom[data-muc="vua"] > i { color: var(--text-status-warning); }
.cc-ll-tom[data-muc="yeu"] { border-left-color: var(--color-danger); }
.cc-ll-tom[data-muc="yeu"] > i { color: var(--text-status-critical); }
.cc-ll-che { margin-bottom: 16px; }
.cc-ll-bd[hidden], .cc-ll-tuan[hidden] { display: none; }
.cc-ll-che button { min-height: 40px; padding: 0 14px; font-size: 14px; }
.cc-ll-khung { --ll-nhan: 208px; --ll-ke: 16px; position: relative; }
@media (max-width: 720px) { .cc-ll-khung { --ll-nhan: 96px; --ll-ke: 8px; } }
.cc-ll-thuoc, .cc-ll-hang, .cc-ll-giayr { display: grid; grid-template-columns: var(--ll-nhan) minmax(0, 1fr); column-gap: var(--ll-ke); align-items: center; }
.cc-ll-thuoc, .cc-ll-lich, .cc-ll-giayr { position: relative; z-index: 1; }
.cc-ll-thuoc { font-size: 12px; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.cc-ll-thuoc__truc { position: relative; height: 22px; }
.cc-ll-thuoc__truc > span { position: absolute; bottom: 3px; padding-inline: var(--space-1); white-space: nowrap; background: var(--surface-card); }
.cc-ll-thuoc__truc .cc-ll-nhan-nay[data-xa] { display: inline-flex; align-items: center; gap: var(--space-1); padding-left: 0; font-weight: 400; color: var(--text-secondary); }
.cc-ll-thuoc__truc > span[data-phai] { transform: translateX(-100%); padding: 0 5px 0 0; }
.cc-ll-thuoc__truc .cc-ll-nhan-nay { font-weight: 600; color: var(--text-status-critical); }
.cc-ll-thuoc__truc .cc-ll-nhan-ra { top: 3px; bottom: auto; font-weight: 600; color: var(--text-brand); }
.cc-ll-lich { list-style: none; margin: 0; padding: 0; border-block: 1px solid var(--hairline); }
.cc-ll-lich > li + li { border-top: 1px solid var(--hairline); }
.cc-ll-hang { width: 100%; min-height: 52px; padding: 8px 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.cc-ll-hang:hover .cc-ll-ten b, .cc-ll-hang[aria-pressed="true"] .cc-ll-ten b { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.cc-ll-hang[aria-pressed="true"] .cc-ll-ten b { color: var(--text-brand); }
.cc-ll-hang:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }
.cc-ll-ten { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: 12px; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.cc-ll-ten b { font-size: 14px; line-height: 1.35; color: var(--text-primary); }
.cc-ll-the { font-weight: 600; color: var(--text-status-critical); }
@media (max-width: 720px) { .cc-ll-ten > span:not(.cc-ll-the) { display: none; } .cc-ll-ten b { font-size: 13px; } }
.cc-ll-truc { position: relative; display: block; height: 22px; }
.cc-ll-thanh, .cc-ll-qua, .cc-ll-sx { position: absolute; top: 4px; bottom: 4px; border-radius: var(--radius-sm); }
.cc-ll-thanh { z-index: 1; background: var(--color-studio-blue); }
.cc-ll-qua { z-index: 2; border-radius: var(--radius-sm) 0 0 var(--radius-sm); background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--color-danger) 70%, var(--surface-card)) 0 1.5px, var(--surface-card) 1.5px 6px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-danger) 55%, var(--surface-card)); }
.cc-ll-sx { z-index: 1; background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--color-studio-blue) 50%, var(--surface-card)) 0 3px, var(--surface-card) 3px 7px); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--color-studio-blue) 50%, var(--surface-card)); }
.cc-ll-kc { position: absolute; top: 50%; width: 10px; height: 10px; margin: -5px 0 0 -5px; transform: rotate(45deg); background: var(--color-bordeaux); }
.cc-ll-kc:has(i) { width: 16px; height: 16px; margin: -8px 0 0 -8px; }
.cc-ll-kc i { position: absolute; inset: 0; display: grid; place-items: center; transform: rotate(-45deg); font: 600 10px/1 var(--font-sans); font-style: normal; color: var(--color-white); }
.cc-ll-giayr { border-bottom: 1px solid var(--hairline); }
.cc-ll-phu { position: absolute; top: 0; bottom: 0; right: 0; left: calc(var(--ll-nhan) + var(--ll-ke)); z-index: 0; pointer-events: none;
  background-image: linear-gradient(to right, color-mix(in srgb, var(--hairline) 70%, transparent) 1px, transparent 1px); background-size: var(--ll-tuan) 100%; background-position: var(--ll-tuan-x) 0; }
.cc-ll-phu--tren { z-index: 2; background: none; }
/* lưới và vạch tháng bắt đầu dưới hàng nhãn tháng: vạch không cắt chữ ở khổ hẹp */
.cc-ll-khung > .cc-ll-phu { top: 22px; }
.cc-ll-vthang { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--border-strong); }
.cc-ll-vung { position: absolute; top: 0; bottom: 0; background: color-mix(in srgb, var(--color-studio-blue) 9%, transparent); }
.cc-ll-vung[data-loai="tet"] { background: color-mix(in srgb, var(--color-warning) 16%, transparent); }
.cc-ll-vung[data-loai="tranh"] { background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--color-warning) 22%, transparent) 0 4px, transparent 4px 9px); }
.cc-ll-vnay { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: var(--color-signal-red); }
.cc-ll-vra { position: absolute; top: 0; bottom: 0; width: 3px; margin-left: -1.5px; border-radius: 2px; background: var(--color-bordeaux); }
.cc-ll-noi { position: absolute; width: 0; margin-left: -1px; border-left: 2px dotted var(--text-secondary); }
.cc-ll-noi::after { content: ""; position: absolute; bottom: -3px; left: -4px; width: 6px; height: 6px; border-radius: 50%; background: var(--text-secondary); }
.cc-ll-chu { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 16px; margin: 12px 0 0; padding: 0; font-size: 12px; color: var(--text-secondary); }
.cc-ll-chu li { display: inline-flex; align-items: center; gap: 6px; }
@media (max-width: 720px) {
  .cc-ll-chu { display: grid; grid-template-columns: 1fr 1fr; }
  .cc-ll-chu li:has(.cc-ll-vung) { grid-column: 1 / -1; }
}
.cc-ll-chu li > span { position: relative; display: inline-block; flex: none; top: auto; bottom: auto; left: auto; width: 20px; height: 12px; margin: 0; transform: none; }
.cc-ll-chu .cc-ll-vnay, .cc-ll-chu .cc-ll-noi { width: 2px; height: 14px; }
.cc-ll-chu .cc-ll-vra { width: 3px; height: 14px; }
.cc-ll-chu .cc-ll-noi::after { bottom: -2px; left: -4px; }
.cc-ll-chu .cc-ll-kc { width: 9px; height: 9px; transform: rotate(45deg); }
.cc-ll-chi { margin-top: 12px; padding: 12px 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); font-size: 14px; line-height: 1.6; }
.cc-ll-chi p { margin: 0 0 6px; }
.cc-ll-chi p.cc-goi-y { margin: 0; }
.cc-ll-chi p[data-muc="yeu"] { color: var(--text-status-critical); }
.cc-ll-chi ul { margin: 0; padding-left: 20px; color: var(--text-secondary); }
.cc-ll-tuan { list-style: none; display: grid; gap: 12px; margin: 0; padding: 0; }
.cc-ll-tuan > li { padding: 12px 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); }
.cc-ll-tuan > li[data-loai="qua"] { border-left: 3px solid var(--color-danger); }
.cc-ll-tuan > li[data-loai="nay"] { border-color: var(--brand); box-shadow: inset 3px 0 0 var(--brand); }
.cc-ll-tuan > li[data-loai="ra"] { background: var(--surface-paper); border-color: var(--hairline); }
.cc-ll-tuan__dau { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 8px; margin: 0 0 8px; font-size: 13px; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.cc-ll-tuan__dau b { font: 600 16px var(--font-heading); color: var(--text-primary); }
.cc-ll-tuan > li[data-loai="qua"] .cc-ll-tuan__dau b { color: var(--text-status-critical); }
.cc-ll-tuan ul { list-style: none; display: grid; gap: 8px; margin: 0; padding: 0; }
.cc-ll-tuan ul li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 8px; font-size: 14px; line-height: 1.5; }
.cc-ll-tuan ul li > i { margin-top: 3px; color: var(--color-studio-blue); }
.cc-ll-tuan ul li small { display: block; font-size: 13px; color: var(--text-secondary); text-wrap: pretty; }
.cc-ll-tuan li[data-k="xong"] > i { color: var(--text-status-success); }
.cc-ll-tuan li[data-k="ghi"] > i { color: var(--text-secondary); }
.cc-ll-tuan > li[data-loai="qua"] .cc-ll-the { font-weight: 400; }
.cc-ll-tuan li[data-k="ra"] > i { color: var(--text-brand); }
.cc-ll-tuan li[data-k="dang"] > i, .cc-ll-tuan li[data-k="ghi"] > i { color: var(--text-secondary); }
.cc-ll-tuan > li[data-loai="qua"] ul li > i { color: var(--text-status-critical); }
.cc-ll-viec { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 12px; }
.cc-ll-viec > li { padding: 12px 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); }
.cc-ll-viec p { margin: 0 0 6px; font-size: 14px; }
.cc-ll-viec ul { margin: 0; padding-left: 20px; font-size: 13px; color: var(--text-secondary); line-height: 1.6; }

/* ================= công cụ: tự chấm sức khoẻ thương hiệu (cc-tc-, 20/10/2026) =================
   Mười hai câu cao hơn màn hình: bảng nhập KHÔNG dính khi cuộn, kẻo câu cuối không cuộn tới được. */
.cc-app__vao:has(.cc-tc-cau) { position: static; }
.cc-tc-cau { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 16px; counter-reset: tc; }
.cc-tc-cau > li { counter-increment: tc; display: flex; flex-direction: column; gap: 8px; padding-bottom: 16px; border-bottom: 1px solid var(--hairline); }
.cc-tc-cau > li:last-child { border-bottom: 0; padding-bottom: 0; }
.cc-tc-cau p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--text-primary); }
/* số câu lấy từ data-so: điện thoại ẩn các câu khác (display none) nên bộ đếm CSS đếm sai */
.cc-tc-cau p::before { content: attr(data-so) ". "; font-weight: 600; color: var(--text-secondary); }
.cc-tc-tru { font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--text-secondary); }
.cc-app .cc-tc-nut { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 6px; }
.cc-app .cc-tc-nut button { white-space: nowrap; }
.cc-app .cc-tc-nut button { min-height: 44px; padding: 0 8px; font-size: 13px; justify-content: center; }
.cc-tc-thanh { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 10px; }
.cc-tc-thanh li { display: grid; grid-template-columns: 96px minmax(0, 1fr) 40px; gap: 12px; align-items: center; font-size: 14px; }
.cc-tc-thanh b { font-variant-numeric: tabular-nums; text-align: right; }
.cc-tc-thanh__truc { height: 10px; border-radius: 5px; background: var(--surface-page); box-shadow: inset 0 0 0 1px var(--hairline); overflow: hidden; }
.cc-tc-thanh__truc span { display: block; height: 100%; background: var(--color-success); }
.cc-tc-thanh li[data-muc="vua"] .cc-tc-thanh__truc span { background: var(--color-warning); }
.cc-tc-thanh li[data-muc="yeu"] .cc-tc-thanh__truc span { background: var(--color-danger); }
.cc-tc-lam { margin: 12px 0 0; padding-left: 20px; display: grid; gap: 12px; font-size: 14px; }
.cc-tc-lam ul { margin: 6px 0 0; padding-left: 18px; color: var(--text-secondary); line-height: 1.6; font-size: 13px; }
.cc-tc-lam a { color: var(--text-brand); font-weight: 600; text-underline-offset: 3px; }

/* ================= công cụ: kiểm tra nhãn bắt buộc (cc-nb-, 20/10/2026) ================= */
.cc-nb-loai { max-width: none; }
textarea.cc-nb-chu { min-height: 168px; }
.cc-nb-xn { margin-top: 20px; padding: 16px 20px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-page); display: flex; flex-direction: column; gap: 4px; }
.cc-nb-xn .cc-qr-hop { min-height: 40px; align-items: flex-start; line-height: 1.45; }
.cc-nb-xn .cc-qr-hop input { margin-top: 2px; flex: none; }
.cc-nb-luuy { display: flex; gap: 6px; margin-top: 16px; }

/* ================= công cụ: chấm website (cc-cw-, 20/10/2026) ================= */
#cc-cw-cham { align-self: stretch; justify-content: center; }
.cc-cw-cho { display: flex; gap: 6px; align-items: center; margin-top: 12px; }

/* ---------- tầng sâu (20/10/2026): việc cần làm · đoạn mã · phiếu mang đi · in riêng phiếu ---------- */
.cc-viec { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 12px; }
.cc-viec > li { border: 1px solid var(--border-subtle); border-left: 3px solid var(--color-warning); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-viec > li[data-muc="yeu"] { border-left-color: var(--color-danger); }
.cc-viec summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 16px 20px; min-height: 44px; }
.cc-viec summary::-webkit-details-marker { display: none; }
.cc-viec summary > i { transition: transform var(--dur-base) var(--ease-out); color: var(--text-secondary); }
.cc-viec details[open] summary > i { transform: rotate(180deg); }
.cc-viec__so { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 14px;
  background: var(--surface-paper); color: var(--text-primary); font-variant-numeric: tabular-nums; }
.cc-viec__tieu { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.cc-viec__tieu b { font-size: 15px; font-weight: 600; line-height: 1.4; }
.cc-viec__muc { font-size: 13px; font-weight: 600; color: var(--text-status-warning); }
li[data-muc="yeu"] .cc-viec__muc { color: var(--text-status-critical); }
.cc-viec__ruot { padding: 0 20px 20px 60px; display: grid; gap: 12px; }
.cc-viec__hau { margin: 0; display: flex; gap: 8px; font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
.cc-viec__hau i { flex: none; margin-top: 3px; color: var(--text-status-warning); }
.cc-viec__buoc { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 15px; line-height: 1.6; color: var(--text-primary); }
.cc-viec__buoc li::marker { color: var(--text-secondary); font-variant-numeric: tabular-nums; }
@media (max-width: 640px) { .cc-viec summary { padding: 14px 16px; gap: 10px; } .cc-viec__ruot { padding: 0 16px 16px; } }

.cc-ma { border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); overflow: hidden; background: var(--surface-page); min-width: 0; }
.cc-ma__dau { display: flex; align-items: center; gap: 12px; padding: 6px 6px 6px 12px; border-bottom: 1px solid var(--border-subtle); font-size: 13px; color: var(--text-secondary); }
.cc-ma__dau > span:first-child { flex: 1; min-width: 0; }
.cc-ma__bao { font-size: 13px; color: var(--text-status-success); }
.cc-ma__nut { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm);
  background: var(--surface-card); color: var(--text-primary); font: 600 13px var(--font-sans); cursor: pointer;
  text-align: left; line-height: 1.35; padding-block: 8px; max-width: 100%; }
.cc-ma__nut i { flex: none; }
.cc-ma__nut:hover { border-color: var(--border-strong); }
.cc-ma pre { margin: 0; padding: 12px; overflow-x: auto; font: 13px/1.6 var(--font-mono); white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text-primary); }

.cc-phieus { margin-top: 8px; }
/* QC 26/10: điện thoại gập bản xem trước phiếu, hàng nút đứng trên */
.cc-phieu-gap { margin-top: 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-phieu-gap > summary { display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; cursor: pointer; list-style: none; font-weight: 600; font-size: 15px; color: var(--text-primary); }
.cc-phieu-gap > summary::-webkit-details-marker { display: none; }
.cc-phieu-gap__mo { margin-left: auto; color: var(--text-secondary); transition: transform var(--dur-base) var(--ease-out); }
.cc-phieu-gap[open] .cc-phieu-gap__mo { transform: rotate(180deg); }
.cc-phieu-gap[open] > .cc-phieu { margin: 0 12px 12px; }
@media (prefers-reduced-motion: reduce) { .cc-phieu-gap__mo { transition-duration: 0.001ms; } }
.cc-phieu { margin-top: 16px; border: 1px solid var(--hairline); border-radius: var(--radius-md); background: var(--surface-card); padding: 24px; }
.cc-phieu__dau { padding-bottom: 16px; border-bottom: 1px solid var(--hairline); }
.cc-phieu__tieu { font-family: var(--font-heading); font-weight: 600; font-size: 20px; line-height: 1.3; margin: 0; color: var(--text-primary); }
.cc-phieu__phu { margin: 4px 0 0; font-size: 14px; color: var(--text-secondary); }
.cc-phieu__than { display: grid; gap: 20px; margin-top: 16px; }
.cc-phieu__h { margin: 0 0 8px; font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-caps); text-transform: uppercase; color: var(--text-secondary); }
.cc-phieu dl { margin: 0; display: grid; grid-template-columns: minmax(120px, 34%) minmax(0, 1fr); gap: 8px 16px; font-size: 14px; line-height: 1.55; }
.cc-phieu dt { color: var(--text-secondary); }
.cc-phieu dd { margin: 0; color: var(--text-primary); overflow-wrap: anywhere; }
.cc-phieu__ghis { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--hairline); }
.cc-phieu__ghi { margin: 0; padding: 0 0 0 20px; font-size: 13px; line-height: 1.6; color: var(--text-secondary); display: grid; gap: 4px; }
.cc-phieu__chan { margin-top: 16px; font-size: 12px; color: var(--text-secondary); }
@media (max-width: 640px) { .cc-phieu { padding: 16px; } .cc-phieu dl { grid-template-columns: 1fr; gap: 2px; } .cc-phieu dd { margin-bottom: 8px; } }

.cc-hanh { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 12px; }
.cc-hanh__bao { flex-basis: 100%; }
@media (max-width: 640px) { .cc-hanh .sv-btn { flex: 1 1 100%; justify-content: center; } }

.cc-so-truoc { margin: 12px 0 0; padding: 12px 16px; border-radius: var(--radius-sm); background: var(--surface-paper); font-size: 14px; line-height: 1.6; color: var(--text-primary); display: flex; gap: 8px; }
.cc-so-truoc i { flex: none; margin-top: 3px; }

#cc-in { display: none; }
@media print {
  html.cc-dang-in body > *:not(#cc-in) { display: none !important; }
  html.cc-dang-in #cc-in { display: block; }
  html.cc-dang-in #cc-in .cc-phieu { border: 0; padding: 0; }
  html.cc-dang-in .cc-phieu dl { grid-template-columns: 34% 66%; }
  html.cc-dang-in .cc-phieu__nhom { break-inside: avoid; }
  @page { size: A4; margin: 16mm; }
}
@media (prefers-reduced-motion: reduce) { .cc-viec summary > i { transition-duration: 0.001ms; } }
.cc-soi-gap { margin-top: 24px; border-top: 1px solid var(--hairline); }
.cc-soi-gap .cc-soi { margin: 0 0 16px; }
.cc-sm-doi { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; font-variant-numeric: tabular-nums; }
.cc-sm-doi i { color: var(--text-secondary); }
.cc-sm-dois { display: grid; gap: 8px; }
.cc-hanh__bao:empty { display: none; }
.cc-cw-tep { min-width: 0; }
.cc-cw-tep ul { margin: 6px 0 0; padding-left: 20px; display: grid; gap: 4px; font-size: 13px; line-height: 1.5; }
.cc-cw-tep code { font: 12px/1.5 var(--font-mono); overflow-wrap: anywhere; color: var(--text-secondary); }

/* ---------- Chọn bộ màu (công cụ 18, 22/10/2026) ----------
   Màu bộ là NỘI DUNG do chon-mau.js tính (lõi #216), gán nội tuyến hoặc qua biến --m-*; khung chỉ dùng token.
   Ảnh xem thử dùng kiểu chung mau-anh.css (tnm-tp, tnm-khung, tnm-anh). */
.cc-cm-khoi { display: grid; gap: 24px; min-width: 0; }
.cc-cm-tuy { margin-left: 8px; font-size: 12px; font-weight: 500; color: var(--text-secondary); }
.cc-cm-tuy--nen { color: var(--text-brand); font-weight: 600; }
/* vị trí trong ngành: một dòng ngay dưới kết luận (28/10); không khung, không viền nhấn, kẻo tranh điểm nhấn với thẻ kết luận (gac-ui-ux) */
.cc-cm-vitri { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; padding: 0 0 0 2px; }
.cc-cm-vitri > p { flex: 1 1 320px; }
.cc-cm-vitri__nhan { flex-basis: 100%; }
.cc-cm-vitri--chua { padding: 16px 20px; border: 1px solid var(--hairline); border-radius: var(--radius-md); background: var(--surface-paper); }
.cc-cm-vitri__nhan { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-wide); color: var(--text-brand); }
.cc-cm-vitri p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-primary); }
.cc-cm-vitri__nut { justify-self: start; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px; border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--surface-card); color: var(--text-primary); font: inherit; font-weight: 600; cursor: pointer; }
.cc-cm-vitri__nut:hover { border-color: var(--text-primary); text-decoration: underline; text-underline-offset: 3px; }
/* hiểu thêm về ngành: lối sang trang ngành, nhánh, dự án cùng ngành (28/10) */
.cc-cm-doc { display: grid; gap: 12px; padding-top: 24px; border-top: 1px solid var(--hairline); }
.cc-cm-doc__le { margin: 0; color: var(--text-secondary); line-height: 1.6; }
.cc-cm-doc__ds, .cc-cm-doc__ca { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cc-cm-doc__lien { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 12px 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); color: var(--text-primary); text-decoration: none; }
.cc-cm-doc__lien > span { display: grid; gap: 2px; flex: 1; min-width: 0; }
.cc-cm-doc__lien b { font-weight: 600; }
.cc-cm-doc__lien span span { font-size: 14px; color: var(--text-secondary); }
.cc-cm-doc__lien .ph-arrow-right { transition: transform var(--dur-fast) var(--ease-out); }
.cc-cm-doc__lien:hover { border-color: var(--border-strong); }
.cc-cm-doc__lien:hover b { text-decoration: underline; text-underline-offset: 3px; }
.cc-cm-doc__lien:hover .ph-arrow-right { transform: translateX(3px); }
.cc-cm-doc__nhan { margin: 8px 0 0; font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-wide); color: var(--text-secondary); }
.cc-cm-doc__ca { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.cc-cm-doc__ca a { display: grid; gap: 6px; align-content: start; color: var(--text-primary); text-decoration: none; }
.cc-cm-doc__ca img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--radius-md); border: 1px solid var(--border-subtle); }
@media (max-width: 640px) {
  .cc-cm-doc__ca { grid-template-columns: 1fr; gap: 12px; }
  .cc-cm-doc__ca a { grid-template-columns: 112px minmax(0, 1fr); column-gap: 12px; row-gap: 2px; }
  .cc-cm-doc__ca img { grid-row: span 2; }
}
.cc-cm-doc__ca b { font-weight: 600; }
.cc-cm-doc__ca span { font-size: 14px; line-height: 1.5; color: var(--text-secondary); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cc-cm-doc__ca a:hover b { text-decoration: underline; text-underline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .cc-cm-doc__lien .ph-arrow-right { transition: none; } }
/* màu hay dùng theo từng ngành, chữ đúc sẵn trong Về công cụ này (28/10) */
.cc-mbn { display: grid; gap: 16px; align-items: start; }
@media (min-width: 980px) { .cc-mbn { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.cc-mbn__o { display: grid; gap: 8px; align-content: start; padding: 16px 20px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-mbn__o h3 { margin: 0; font-family: var(--font-heading); font-weight: 600; font-size: 18px; }
.cc-mbn__o p { margin: 0; line-height: 1.6; color: var(--text-secondary); }
.cc-mbn__bo { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.cc-mbn__bo li { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.cc-mbn__bo i { width: 16px; height: 16px; border-radius: var(--radius-sm); border: 1px solid var(--border-subtle); flex: none; }
.cc-mbn__bo span { font-weight: 400; font-size: 14px; color: var(--text-secondary); }
.cc-mbn__lien { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.cc-mbn__lien a { color: var(--text-primary); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--hairline); }
.cc-mbn__lien a:hover { text-decoration-color: currentColor; }
.cc-cm-menh { min-height: 40px; }
.cc-cm-bo { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 8px; }
.cc-cm-o { display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; min-width: 0; min-height: 168px; padding: 14px; border-radius: var(--radius-md); border: 1px solid var(--border-subtle); }
.cc-cm-o b { font: 600 18px/1.2 var(--font-heading); }
.cc-cm-o__vai { font-size: 12px; font-weight: 600; letter-spacing: var(--tracking-wide); opacity: .85; margin-bottom: auto; }
.cc-cm-o__ma { font: 13px/1.4 var(--font-mono); }
.cc-cm-o__loi { font-size: 12px; line-height: 1.45; opacity: .85; margin-top: 4px; }
.cc-cm-ly { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 15px; line-height: 1.6; color: var(--text-primary); }
.cc-cm-bep { display: grid; gap: 16px; min-width: 0; }
.cc-cm-bep > .cc-kq__h3 { margin-bottom: -4px; }
.cc-cm-bep + .cc-cm-khoi { margin-top: 24px; }
.cc-cm-truc { gap: 16px; }
.cc-cm-truc > span:first-child { white-space: nowrap; }
.cc-cm-truc > span + span { text-align: right; }
.cc-cm-ban { display: grid; gap: 8px; }
.cc-cm-truc { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-secondary); }
.cc-cm-pad { position: relative; height: 168px; border-radius: var(--radius-md); overflow: hidden; cursor: crosshair; touch-action: none; border: 1px solid var(--border-subtle); }
.cc-cm-pad:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-cm-nen { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.cc-cm-cham { position: absolute; width: 24px; height: 24px; translate: -50% -50%; border-radius: 50%; border: 2px solid var(--color-white); box-shadow: 0 0 0 1px var(--border-strong), 0 2px 6px -2px rgba(3, 29, 68, .3); pointer-events: none; }
.cc-cm-ruc-nhan { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; font-size: 13px; color: var(--text-secondary); }
.cc-cm-ruc { width: 100%; height: 44px; accent-color: var(--color-bordeaux); }
.cc-cm-thang { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-radius: var(--radius-md); overflow: hidden; }
.cc-cm-thang li { display: flex; flex-direction: column; justify-content: space-between; min-height: 72px; padding: 8px; font-size: 11px; line-height: 1.3; min-width: 0; }
.cc-cm-thang b { font: 600 15px/1 var(--font-heading); }
.cc-cm-thang li[data-gan] { box-shadow: inset 0 0 0 2px currentColor; }
.cc-cm-xem { display: grid; gap: 12px; }
/* isolation: ảnh mẫu NHÂN màu (mau-anh.css) chỉ trộn với sân này; thiếu nó phép nhân trộn với cả khung cuộn,
   Safari iPhone đặt lại đầu trang chậm một nhịp, vuốt xuống thì đầu trang nháy, hở khe (23/10, như .tnm-san, .xtt-khung) */
.cc-cm-san { isolation: isolate; display: grid; grid-template-columns: 3fr 2fr 2fr; gap: 16px; align-items: end; padding: 24px; border-radius: var(--radius-md); background: var(--san-anh, var(--surface-page)); }
.cc-cm-san .tnm-tp--the { grid-column: 1 / -1; }
.cc-cm-san .tnm-tp--the .tnm-khung { max-width: 560px; margin: 0 auto; }
.cc-cm-a4__giay { aspect-ratio: 210 / 297; background: var(--color-white); border-radius: 2px; box-shadow: 0 6px 18px -8px rgba(3, 29, 68, .25); }
.cc-cm-a4__giay svg { display: block; width: 100%; height: 100%; }
@media (max-width: 980px) { .cc-cm-bo { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cc-cm-o { min-height: 128px; } }
@media (max-width: 640px) {
  .cc-cm-san { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 12px; }
  .cc-cm-san figcaption { font-size: 11px; line-height: 16px; }
  .cc-cm-thang span { display: none; }
  .cc-cm-thang li { min-height: 48px; align-items: center; justify-content: center; }
  .cc-cm-pad { height: 144px; }
  /* bộ màu thành dải bốn ô ngay trên bàn chỉnh: bộ màu, bảng kéo, thanh rực gọn trong một màn điện thoại */
  .cc-cm-bep { gap: 12px; }
  .cc-cm-bo { grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr)); gap: 4px; }
  .cc-cm-o { min-height: 96px; padding: 8px; gap: 2px; border-radius: var(--radius-sm); }
  .cc-cm-o__vai { font-size: 10px; letter-spacing: 0; }
  .cc-cm-o b { font-size: 13px; line-height: 1.2; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
  .cc-cm-o__ma { font-size: 10px; }
  .cc-cm-o__loi { display: none; }
}

/* ================= bộ gợi ý theo ngành: màu + cặp chữ tự host (cc-cm-boke, cc-cm-chu, cc-cm-logo; đợt 2 ngày 27/10/2026) ================= */
.cc-cm-nhanh { display: grid; gap: 6px; margin-top: 12px; }
.cc-cm-nhanh__nhan { font-size: 14px; font-weight: 600; color: var(--text-primary); }
.cc-cm-bo-nganh { display: grid; gap: 12px; }
.cc-cm-bo__le { margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-primary); max-width: 64ch; }
.cc-cm-boke{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:minmax(0,1fr);gap:var(--space-6)}
/* bốn bộ chia hai hàng hai cột (anh chốt 28/10), điện thoại một cột */
@media (min-width:720px){.cc-cm-boke{grid-template-columns:repeat(2,minmax(0,1fr))}}
.cc-cm-bo__khac{margin-top:var(--space-4);justify-self:start;width:auto}
.cc-cm-bo__nguon{margin:0;font-size:12px;line-height:1.5;color:var(--text-secondary)}
.cc-cm-bo__nguon a{color:inherit}
/* thẻ bộ màu khuôn C (anh chốt 28/10/2026 theo ảnh mẫu nhan-dien/xem-truoc/mau-c-anh-chot.png; chép luật từ nv2.css .nv2-bo,
   sửa hai nơi cùng lượt): thẻ trắng viền mảnh; đầu số + tên bộ + cảm giác chữ hoa; thân trái chấm màu + mã + câu vì sao, phải ảnh
   dọc trơn, không đè chữ; đáy nhãn bo tròn. Màu bộ đi nội tuyến (chon-mau.js): --bo-chinh nền nhãn, --bo-nen nền khung ảnh, --bo-chu viền chọn. */
.cc-cm-bomuc{display:flex;min-width:0;container-type:inline-size}
.cc-cm-bothe{width:100%;display:grid;font:inherit;text-align:left;cursor:pointer;grid-template-columns:minmax(0,1fr) 28%;grid-template-rows:auto 1fr auto;
  grid-template-areas:"dau dau" "trai anh" "nhan nhan";column-gap:var(--space-4);padding:var(--space-6);background:var(--surface-card);
  border:1px solid var(--border-subtle);border-radius:var(--radius-lg);text-decoration:none;color:var(--text-primary);
  transition:transform var(--dur-base) var(--ease-out),box-shadow var(--dur-base) var(--ease-out),border-color var(--dur-base) var(--ease-out)}
.cc-cm-bothe__dau{grid-area:dau;display:flex;align-items:baseline;gap:var(--space-2);margin-bottom:var(--space-4)}
.cc-cm-bothe__so{flex:none;font:500 13px/1.5 var(--font-mono);font-variant-numeric:tabular-nums;color:var(--text-secondary)}
.cc-cm-bothe__dt{display:flex;flex-direction:column;gap:6px;min-width:0}
.cc-cm-bothe__ten{font:700 clamp(20px, 7.5cqi, 28px)/1.15 var(--font-heading);letter-spacing:-.01em}
.cc-cm-bothe__cg{font-size:11px;font-weight:600;line-height:1.5;letter-spacing:var(--tracking-caps);text-transform:uppercase;color:var(--text-secondary)}
.cc-cm-bothe__trai{grid-area:trai;display:flex;flex-direction:column;gap:var(--space-4);min-width:0}
.cc-cm-bothe__mau{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--space-2)}
.cc-cm-bothe__o{display:flex;flex-direction:column;align-items:center;gap:var(--space-2);min-width:0}
.cc-cm-bothe__cham{display:block;width:100%;aspect-ratio:1;border-radius:50%}
.cc-cm-bothe__cham--sang{box-shadow:inset 0 0 0 1px var(--border-strong)}
.cc-cm-bothe__hex{font:600 12px/1 var(--font-heading);letter-spacing:.02em;color:var(--text-primary);white-space:nowrap}
.cc-cm-bothe__ta{font-size:15px;line-height:1.55}
.cc-cm-bothe__anh{grid-area:anh;position:relative;display:block;align-self:start;aspect-ratio:3/5;border-radius:var(--radius-md);overflow:hidden;background:var(--bo-nen)}
.cc-cm-bothe__anh img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.cc-cm-bothe__anh{container-type:inline-size}
/* dải nhãn giấy chạy hết đáy ảnh (gac-ui-ux 28/10): lề dọc bằng viền trong suốt để dòng thứ ba bị giấu hẳn, đường kẻ trong như nhãn in */
.cc-cm-bothe__tenanh{position:absolute;left:0;right:0;bottom:0;padding:0 var(--space-1);border:var(--space-2) solid transparent;background:var(--t-nen);color:var(--t-chu);
  font:700 clamp(12px, 15cqi, 22px)/1.25 var(--p-tieu, var(--font-heading));text-align:center;overflow-wrap:anywhere;text-wrap:balance;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;
  outline:1px solid color-mix(in srgb, var(--t-chu) 22%, transparent);outline-offset:-5px}
/* tên trên 18 ký tự: ảnh 1440 chỉ rộng khoảng 96px, hai dòng ở 9px vẫn không vừa 40 ký tự, nên cho ba dòng */
.cc-cm-bothe__tenanh[data-dai]{font-size:clamp(10px, 11cqi, 16px);-webkit-line-clamp:3}
.cc-cm-bothe__tenanh--sang{box-shadow:inset 0 1px 0 var(--border-strong)}
.cc-cm-bothe__anh:not(:has(img)) .cc-cm-bothe__tenanh{top:50%;bottom:auto;transform:translateY(-50%);background:none;outline:0;box-shadow:none;font-size:clamp(14px, 18cqi, 28px)}
.cc-cm-bothe__tenanh[hidden]{display:none}
.cc-cm-bothe__nhan{grid-area:nhan;display:flex;flex-wrap:nowrap;overflow:hidden;gap:var(--space-2);margin-top:var(--space-6)}
.cc-cm-bothe__nhan span{padding:5px 12px;border-radius:var(--radius-pill);background:color-mix(in srgb,var(--bo-chinh) 9%,var(--surface-card));font-size:13px;font-weight:500;line-height:1.35;white-space:nowrap;flex:none}
.cc-cm-bothe__nhan span:last-child:not(:first-child){flex-shrink:1;min-width:0;overflow:hidden;text-overflow:ellipsis}
.cc-cm-bothe:focus-visible{outline:none;box-shadow:var(--ring)}
@media (hover:hover){.cc-cm-bothe:hover{transform:translateY(-2px);border-color:var(--border-strong);box-shadow:var(--shadow-md, var(--shadow-sm))}}
/* đang chọn: viền 2px cách 2px màu chữ của bộ; nhãn Đang dùng đặc màu */
.cc-cm-bothe.tt-chon{outline:2px solid var(--bo-chu, var(--text-primary));outline-offset:2px;border-color:transparent}
/* trang-thai.css (nạp sau, qua _worker.js) tô nền mực cho mọi .tt-chon[aria-pressed=true]; thẻ bộ giữ nền trắng, kẻo mã màu
   dưới chấm chìm vào nền (28/10: bộ đầu kệ tự chọn nên lỗi hiện mọi lần mở trang) */
.cc-cm-bothe.tt-chon[aria-pressed="true"]{background-color:var(--surface-card);color:var(--text-primary)}
.cc-cm-bothe__nhan .cc-cm-bothe__dang{background:var(--text-primary);color:var(--surface-card)}
@media (prefers-reduced-motion:reduce){.cc-cm-bothe{transition-duration:.001ms}}
/* thẻ hẹp (điện thoại): hàng chấm trải hết bề ngang thẻ để mã màu không dính nhau; câu vì sao + ảnh đứng cạnh nhau bên dưới */
@container (max-width:359px){.cc-cm-bothe{padding:var(--space-4);grid-template-columns:minmax(0,1fr) 36%;grid-template-areas:"dau dau" "mau mau" "trai anh" "nhan nhan";grid-template-rows:auto auto 1fr auto;column-gap:var(--space-3)}.cc-cm-bothe__trai{display:contents}.cc-cm-bothe__mau{grid-area:mau;margin-bottom:var(--space-4)}.cc-cm-bothe__ta{grid-area:trai;font-size:14px}.cc-cm-bothe__cg{letter-spacing:.08em}.cc-cm-bothe__anh{aspect-ratio:3/4}.cc-cm-bothe__nhan{margin-top:var(--space-4)}.cc-cm-bothe__nhan span{font-size:12px}}
.cc-cm-bo__ly { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 8px 16px; font-size: 15px; line-height: 1.6; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-cm-bo__ly dt { font-weight: 600; color: var(--text-primary); }
.cc-cm-bo__ly dd { margin: 0; color: var(--text-primary); }
/* mẫu chữ: tên thương hiệu bằng chữ tiêu đề, câu mẫu bằng chữ nội dung, hàng chữ hai dấu để soi dấu có bị cắt */
.cc-cm-chu { display: grid; gap: 8px; padding: 20px; margin-bottom: 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-cm-chu p { margin: 0; color: var(--text-primary); }
.cc-cm-chu__ten { font: 700 clamp(28px, 2rem + 1vw, 40px)/1.3 var(--p-tieu, var(--font-heading)); overflow-wrap: anywhere; }
.cc-cm-chu__cau { font: 400 16px/1.6 var(--p-noi, var(--font-sans)); }
.cc-cm-chu__dau { font: 700 24px/1.5 var(--p-tieu, var(--font-heading)); letter-spacing: .04em; }
.cc-cm-chu__cap { font-size: 13px; line-height: 1.5; color: var(--text-secondary) !important; }
.cc-cm-san[data-phong] .tnm-ts, .cc-cm-san[data-phong] .tnm-cc { font-family: var(--p-tieu); font-weight: 700; }
/* màu đọc từ logo: ô tròn chạm 44px */
.cc-cm-logo-khoi { display: grid; gap: 8px; }
.cc-cm-logo-khoi .cc-mau { padding: 4px 0; }
.cc-cm-logo[hidden], .cc-cm-nhanh[hidden], .cc-cm-bo-nganh[hidden], .cc-cm-chu[hidden] { display: none; }
.cc-cm-logo { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cc-cm-logo__nhan { flex: 1 0 100%; font-size: 13px; line-height: 1.5; color: var(--text-secondary); }
.cc-cm-logo__o { width: 44px; height: 44px; border-radius: var(--radius-pill); border: 1px solid var(--border-strong); cursor: pointer; padding: 0; }
.cc-cm-logo__o[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--surface-card), 0 0 0 4px var(--text-primary); }
.cc-cm-logo__o:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
@media (max-width: 640px) {
  .cc-cm-bo__ly { grid-template-columns: 1fr; gap: 4px; padding: 12px; }
  .cc-cm-bo__ly dd { margin-bottom: 8px; }
  .cc-cm-chu { padding: 16px; }
}

/* ================= thước màn hình + hộp xem cỡ thật (cc-thuoc-, cc-cothat-, chặng 2, 22/10/2026) ================= */
.cc-thuoc { display: grid; gap: 12px; }
.cc-thuoc__noi { display: flex; align-items: flex-start; min-height: 120px; padding: 8px 0; overflow: hidden; }
.cc-thuoc__the { display: flex; align-items: center; justify-content: center; border: 2px dashed var(--color-studio-blue);
  background: color-mix(in srgb, var(--color-studio-blue) 6%, transparent); }
.cc-thuoc__the span { font-size: 12px; color: var(--text-secondary); }
.cc-thuoc__dk { display: flex; align-items: center; gap: 8px; }
.cc-thuoc__dk input { flex: 1; min-width: 0; accent-color: var(--brand); }
.cc-thuoc__tinh { flex: none; width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--border-strong);
  border-radius: var(--radius-md); background: var(--surface-card); color: var(--text-primary); cursor: pointer; font-size: 18px; }
.cc-thuoc__tinh:focus-visible, .cc-cothat__dong:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-thuoc__nut { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.cc-cothat__thuoc { border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); padding: 0 16px; }
.cc-cothat__thuoc summary { display: flex; align-items: center; gap: 8px; min-height: 48px; cursor: pointer; font-weight: 600; font-size: 14px; }
.cc-cothat__thuoc[open] { padding-bottom: 16px; }
.cc-cothat { width: min(100vw - 32px, 1200px); max-height: calc(100vh - 32px); padding: 20px; border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); background: var(--surface-page); color: var(--text-primary); }
.cc-cothat::backdrop { background: color-mix(in srgb, var(--color-deep-navy) 55%, transparent); }
.cc-cothat__dau { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.cc-cothat__dong { width: 44px; height: 44px; border: 0; border-radius: var(--radius-md); background: none; cursor: pointer; font-size: 22px; color: var(--text-primary); }
.cc-cothat__than { margin-top: 16px; overflow: auto; }
.cc-cothat__hinh { width: max-content; padding: 8px; }
.cc-cothat__hinh svg { display: block; }
.cc-cothat__mat { position: relative; }

/* ================= công cụ: danh thiếp cỡ thật (cc-dt-, 22/10/2026) ================= */
.cc-dt-xem { margin-top: 20px; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-page); }
.cc-dt-san { display: flex; padding: 16px 0; min-height: 160px; overflow-x: auto; overflow-y: hidden; }
/* căn giữa bằng lề tự động chứ không justify-content: thẻ rộng hơn sàn thì vẫn cuộn được tới mép trái, không bị xén */
.cc-dt-khung { position: relative; flex: none; margin-inline: auto; perspective: 1400px; }
.cc-dt-xoay { position: absolute; top: 0; left: 0; transform-origin: 0 0; }
.cc-dt-lat { position: relative; transform-style: preserve-3d; transition: transform 480ms cubic-bezier(.16, 1, .3, 1);
  box-shadow: 0 6px 18px -8px color-mix(in srgb, var(--color-deep-navy) 45%, transparent); }
.cc-dt-lat[data-lat] { transform: rotateY(180deg); }
.cc-dt-mat { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; overflow: hidden; border-radius: inherit;
  backface-visibility: hidden; background: var(--surface-card) center / 100% 100% no-repeat; border: 1px solid var(--border-subtle); }
.cc-dt-mat + .cc-dt-mat { transform: rotateY(180deg); }
.cc-dt-mat span { font-size: 12px; color: var(--text-secondary); }
.cc-dt-an { position: absolute; border: 1px dashed var(--color-studio-blue); opacity: .8; pointer-events: none; }
.cc-dt-dk { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.cc-dt-thang { margin-top: 20px; }
.cc-dt-thang__dong { display: grid; grid-template-columns: 48px minmax(0, 1fr); align-items: baseline; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--border-subtle); }
.cc-dt-thang__dong b { font-size: 12px; font-weight: 600; color: var(--text-secondary); font-variant-numeric: tabular-nums; }
.cc-dt-thang__chu { color: var(--text-primary); line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: clip; font-family: var(--font-sans); }
/* dải nhắc thước (thước là điều kiện để xem, không phải một dòng soát) */
.cc-dt-nhac { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 20px; }
.cc-dt-nhac .cc-goi-y { flex: 1 1 240px; margin: 0; }
.cc-dt-tran__nhan { margin: 8px 0 0; font-size: 14px; font-weight: 600; color: var(--text-primary); }
/* ngăn thước mở thì bỏ dính cột trái, kẻo nút lưu thước nằm dưới đáy màn mà không cuộn tới được */
.cc-app__vao:has(.cc-dt-thuoc[open]) { position: static; }
#cc-dt-lat:disabled { opacity: .5; cursor: not-allowed; }
@media (max-width: 640px) {
  /* bỏ đệm ngang của khung xem để thẻ xoay dọc có thêm 32px, phần điều khiển giữ lề riêng */
  .cc-dt-xem { padding: 16px 0; border-inline: 0; border-radius: 0; }
  .cc-dt-xem > .cc-dt-dk, .cc-dt-xem > .cc-goi-y { padding-inline: 16px; }
}
@media (prefers-reduced-motion: reduce) { .cc-dt-lat { transition-duration: 0.001ms; } }

/* ---------- Chia mã sản phẩm (23/10/2026) ----------
   Bàn nhập hai ô, kết quả mở bằng gợi ý có nút làm ngay; giải nghĩa gập lại (23/10 chiều).
   Năm vùng số mỗi vùng một màu biểu đồ của hệ: nước cấp · doanh nghiệp · sản phẩm · số kiểm tra · loại thùng. */
.cc-qh-dain { border: 1px solid var(--border-subtle); border-radius: var(--radius-md); padding: 0 12px; }
.cc-qh-dain summary { display: flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; font-size: 14px; font-weight: 600; color: var(--text-primary); list-style: none; }
.cc-qh-dain summary::-webkit-details-marker { display: none; }
.cc-qh-dain[open] { padding-bottom: 12px; }
.cc-qh-dain .cc-goi-y { margin-bottom: 8px; }
.cc-qh-suc { display: flex; flex-direction: column; gap: 8px; }
/* 23/10 chiều: bàn nhập hai ô; danh sách sản phẩm một ô, máy nói lại mình hiểu thế nào; giải nghĩa gập sau "?" */
.cc-qh-nhap { min-height: 132px; max-height: 360px; overflow-y: auto; padding: 12px; font-size: 16px; line-height: 1.6; resize: vertical; }
.cc-qh-hieu-dong { margin: 0; display: flex; gap: 8px; align-items: flex-start; padding: 8px 12px; border-radius: var(--radius-sm); background: var(--surface-paper); font-size: 14px; line-height: 1.5; color: var(--text-primary); }
.cc-qh-hieu-dong[hidden], .cc-goi-y[hidden], .cc-qh-meo[hidden] { display: none; }
.cc-qh-meo summary { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; cursor: pointer; list-style: none; font-size: 14px; font-weight: 600; color: var(--text-brand); }
.cc-qh-meo summary::-webkit-details-marker { display: none; }
.cc-qh-meo p, .cc-qh-meo li { margin: 0; font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
.cc-qh-meo ul { margin: 0; padding-left: 20px; display: grid; gap: 4px; }
.cc-qh-them summary > span { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; gap: 0 8px; align-items: baseline; }
.cc-qh-them summary > span span { font-weight: 400; font-size: 13px; color: var(--text-secondary); }
.cc-qh-them summary > i:last-child { color: var(--text-secondary); transition: transform var(--dur-base) var(--ease-out); }
.cc-qh-them[open] summary > i:last-child { transform: rotate(180deg); }
.cc-qh-them__ruot { display: flex; flex-direction: column; gap: 8px; }
.cc-qh-them__nhan { margin: 12px 0 0; font-size: 14px; font-weight: 600; color: var(--text-primary); }
.cc-qh-them__nhan:first-child { margin-top: 4px; }
.cc-qh-goi ul { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.cc-qh-goi li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 8px 12px; padding: 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-qh-goi li > i { margin-top: 3px; font-size: 18px; color: var(--text-brand); }
.cc-qh-goi li[data-muc="yeu"] { border-left: 3px solid var(--color-danger); }
.cc-qh-goi li[data-muc="yeu"] > i { color: var(--text-status-critical); }
.cc-qh-goi p { margin: 0; font-size: 14px; line-height: 1.5; color: var(--text-primary); }
.cc-qh-goi__nut { grid-column: 2; display: flex; flex-wrap: wrap; gap: 8px; }
.cc-qh-bang + .cc-hanh { margin-top: 16px; }
.cc-qh-hieu .cc-qh-hieu__dau { margin: 16px 0 0; font-weight: 600; color: var(--text-primary); }
.cc-qh-hieu .cc-goi-y { margin-top: 4px; }
.cc-qh-buoc__o { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; padding: 16px; }
.cc-qh-buoc__o b { font-size: 15px; line-height: 1.4; }
.cc-hoi .cc-qh-buoc__o p { margin: 4px 0 0; font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
@media (max-width: 980px) { .cc-qh-goi__nut .sv-btn { min-height: 44px; } }
@media (max-width: 640px) {
  .cc-qh-goi__nut { grid-column: 1 / -1; }
  .cc-qh-goi__nut--chon { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cc-qh-goi__nut--chon .sv-btn { padding-left: 4px; padding-right: 4px; justify-content: center; white-space: nowrap; }
}
.cc-qh-ds__ma { font-family: var(--font-mono); font-size: 13px; color: var(--text-primary); white-space: nowrap; font-variant-numeric: tabular-nums; }
.cc-qh-ds [data-thieu] .cc-qh-ds__ma { color: var(--text-status-critical); }

.cc-qh-tach { margin-top: 12px; display: flex; flex-direction: column; gap: 12px; }
.cc-qh-ma { display: flex; gap: 4px; flex-wrap: wrap; }
.cc-qh-ma__vung { --vung: var(--color-deep-navy); flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; align-items: stretch; gap: 6px; padding: 8px 6px; border: 1px solid var(--border-subtle); border-bottom: 3px solid var(--vung); border-radius: var(--radius-sm) var(--radius-sm) 0 0; background: color-mix(in srgb, var(--vung) 9%, var(--surface-card)); cursor: pointer; font: inherit; color: var(--text-primary); }
.cc-qh-ma__vung[data-vung="doanh_nghiep"] { --vung: var(--color-bordeaux); }
.cc-qh-ma__vung[data-vung="san_pham"] { --vung: var(--color-warning); }
.cc-qh-ma__vung[data-vung="kiem"] { --vung: var(--color-success); }
.cc-qh-ma__vung[data-vung="chi_bao"] { --vung: var(--color-studio-blue); }
.cc-qh-ma__vung[aria-pressed="true"] { background: color-mix(in srgb, var(--vung) 18%, var(--surface-card)); border-color: var(--vung); }
.cc-qh-ma__vung:focus-visible { outline: none; box-shadow: var(--ring); }
.cc-qh-ma__so { display: flex; justify-content: center; gap: 2px; font-family: var(--font-mono); font-size: 20px; font-weight: 600; line-height: 1.2; font-variant-numeric: tabular-nums; }
.cc-qh-ma__nhan { font-size: 12px; line-height: 1.3; color: var(--text-secondary); text-align: center; }
.cc-qh-giai { border-left: 3px solid var(--color-warning); padding: 4px 0 4px 16px; font-size: 15px; line-height: 1.65; }
.cc-qh-giai[data-vung="quoc_gia"] { border-left-color: var(--color-deep-navy); }
.cc-qh-giai[data-vung="doanh_nghiep"] { border-left-color: var(--color-bordeaux); }
.cc-qh-giai[data-vung="kiem"] { border-left-color: var(--color-success); }
.cc-qh-giai[data-vung="chi_bao"] { border-left-color: var(--color-studio-blue); }
.cc-qh-giai p { margin: 0 0 8px; }
.cc-qh-giai__dau b { font-family: var(--font-mono); font-size: 16px; }
.cc-qh-giai__luu { display: flex; gap: 8px; color: var(--text-secondary); font-size: 14px; }
.cc-qh-giai__luu i { margin-top: 4px; color: var(--text-brand); }
.cc-qh-tinh { margin-top: 12px; }
.cc-qh-tinh > p { font-size: 15px; line-height: 1.6; margin: 0 0 8px; }
.cc-qh-tinh__o { list-style: none; margin: 0 0 12px; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.cc-qh-tinh__o li { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); font-variant-numeric: tabular-nums; }
.cc-qh-tinh__o li[data-w="3"] { background: var(--surface-paper); }
.cc-qh-tinh__o b { font-family: var(--font-mono); font-size: 18px; }
.cc-qh-tinh__o span { font-size: 12px; color: var(--text-secondary); }
.cc-qh-tinh__o i { font-style: normal; font-size: 13px; font-weight: 600; color: var(--text-brand); }

.cc-qh-bang { margin-top: 12px; display: flex; flex-direction: column; gap: 16px; }
.cc-qh-nhom { border: 1px solid var(--border-subtle); border-radius: var(--radius-md); overflow: hidden; }
.cc-qh-nhom__dau { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; padding: 10px 16px; background: var(--surface-paper); font-size: 14px; }
.cc-qh-nhom__dau span { color: var(--text-secondary); font-size: 13px; }
.cc-qh-ds { list-style: none; margin: 0; padding: 0; }
.cc-qh-ds li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 16px; padding: 10px 16px; border-top: 1px solid var(--hairline); }
.cc-qh-ds li:first-child { border-top: 0; }
.cc-qh-ds__ten { font-size: 14px; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.cc-qh-ds__phu { grid-column: 1 / -1; font-size: 13px; color: var(--text-secondary); overflow-wrap: anywhere; }
.cc-qh-sang { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.cc-qh-buoc .cc-lien { margin-top: 4px; }
@media (max-width: 640px) {
  .cc-qh-ma { gap: 3px; }
  .cc-qh-ma__vung { padding: 6px 3px; }
  .cc-qh-ma__so { font-size: 16px; gap: 0; }
  .cc-qh-ma__nhan { font-size: 11px; }
  .cc-qh-ds li { grid-template-columns: minmax(0, 1fr); }
}
.cc-qh-dain + .cc-tha__mau[hidden], .cc-app .cc-tha__mau[hidden] { display: none; }
.cc-qh-suc[hidden] { display: none; }
.cc-qh-qrvao { display: flex; flex-direction: column; gap: 12px; }
.cc-qh-bat { display: flex; align-items: center; gap: 12px; min-height: 44px; font-size: 15px; font-weight: 600; cursor: pointer; }
.cc-qh-bat input { width: 20px; height: 20px; accent-color: var(--color-bordeaux); }
.cc-qh-qrvao .cc-qr-nhan[hidden] { display: none; }
.cc-qh-qr { margin-top: 12px; display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 16px; align-items: start; }
.cc-qh-qr img { width: 132px; height: 132px; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); background: var(--color-white); padding: 6px; }
.cc-qh-qr p { margin: 8px 0 0; font-size: 15px; line-height: 1.6; }
.cc-qh-qr__url { font-family: var(--font-mono); font-size: 13px; overflow-wrap: anywhere; color: var(--text-primary); }
.cc-qh-ds__qr { grid-column: 1 / -1; justify-self: start; display: inline-flex; align-items: center; gap: 6px; }
ul.cc-qh-loai { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 12px; }
ul.cc-qh-loai li { display: flex; flex-direction: column; gap: 2px; font-size: 15px; line-height: 1.6; }
@media (max-width: 640px) { .cc-qh-qr { grid-template-columns: minmax(0, 1fr); } }
/* 23/10 tối: thẻ từng sản phẩm (hình mã vạch + ba mã mang nhãn dùng vào đâu), dòng máy hiểu, lối Việc tiếp theo.
   Ba nhãn mỗi nhãn một vạch màu trái: in lên hộp (bordeaux) · in lên thùng (xanh studio) · mã kho (xám, không in). */
.cc-chm-hieu { flex-direction: column; gap: 6px; }
.cc-chm-hieu p { margin: 0; }
.cc-chm-hieu__dau { font-weight: 600; }
.cc-chm-hieu ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.cc-chm-hieu li { display: flex; flex-wrap: wrap; gap: 0 8px; align-items: baseline; padding-top: 4px; border-top: 1px solid var(--hairline); }
.cc-chm-hieu li:first-child { border-top: 0; padding-top: 0; }
.cc-chm-hieu li span { color: var(--text-secondary); }
.cc-chm-hieu li em { font-style: normal; font-weight: 600; color: var(--text-brand); margin-left: auto; white-space: nowrap; }
.cc-chm-hieu__tong { font-size: 13px; color: var(--text-secondary); }
.cc-chm-hieu__ds summary { display: inline-flex; align-items: center; gap: 4px; min-height: 32px; cursor: pointer; font-size: 13px; font-weight: 600; color: var(--text-brand); list-style: none; }
.cc-chm-hieu__ds summary::-webkit-details-marker { display: none; }
.cc-chm-hieu__ds[open] summary .ph { transform: rotate(180deg); }
.cc-chm-hieu__ds ul { margin-top: 4px; }
.cc-chm-chu { margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.cc-chm-chu > div, .cc-chm-ma > div { --loai: var(--color-bordeaux); border-left: 3px solid var(--loai); padding-left: 12px; }
.cc-chm-chu > div[data-loai="thung"], .cc-chm-ma > div[data-loai="thung"] { --loai: var(--color-studio-blue); }
.cc-chm-chu > div[data-loai="kho"], .cc-chm-ma > div[data-loai="kho"] { --loai: var(--border-strong); }
.cc-chm-chu dt { font-size: 14px; font-weight: 600; color: var(--text-primary); }
.cc-chm-chu dd { margin: 2px 0 0; font-size: 13px; line-height: 1.5; color: var(--text-secondary); }
.cc-chm-ds { list-style: none; margin: 0; padding: 0; }
.cc-chm-the { display: flex; flex-direction: column; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--hairline); }
.cc-chm-the[data-thieu] .cc-chm-the__ten { color: var(--text-secondary); }
.cc-chm-the:first-child { border-top: 0; }
.cc-chm-the__ten { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.4; color: var(--text-primary); overflow-wrap: anywhere; }
.cc-chm-the__than { display: grid; grid-template-columns: 128px minmax(0, 1fr); gap: 16px; align-items: center; }
.cc-chm-vach { display: block; width: 120px; height: 40px; padding: 4px; box-sizing: content-box; border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); background: var(--color-white); }
.cc-chm-ma { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px 12px; }
.cc-chm-ma dt { font-size: 12px; line-height: 1.3; color: var(--text-secondary); }
.cc-chm-ma dd { margin: 2px 0 0; }
.cc-chm-ma code { font-family: var(--font-mono); font-size: 14px; color: var(--text-primary); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.cc-chm-ma > div[data-loai="hop"] code { font-size: 16px; font-weight: 600; }
.cc-chm-the__nut { display: flex; flex-wrap: wrap; gap: 8px; }
.cc-chm-the__nut .cc-tep__doi { display: inline-flex; align-items: center; gap: 6px; }
.cc-chm-the__giang[hidden] { display: none; }
.cc-chm-the__het { margin: 0; display: flex; gap: 8px; font-size: 14px; color: var(--text-status-critical); }
.cc-chm-ds--mau { margin: 16px auto; max-width: 480px; text-align: left; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-chm-tiep { margin-top: 24px; }
.cc-chm-tiep ol { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.cc-chm-tiep li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
.cc-chm-tiep li b { font-size: 15px; line-height: 1.4; }
.cc-chm-tiep li p { margin: 4px 0 0; font-size: 14px; line-height: 1.6; color: var(--text-secondary); }
.cc-chm-tiep__nut { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.cc-chm-tiep__nut .cc-hanh { margin: 0; }
@media (max-width: 980px) { .cc-chm-the__nut .cc-tep__doi, .cc-chm-tiep__nut .sv-btn, .cc-chm-hieu__ds summary { min-height: 44px; } }
@media (max-width: 640px) {
  .cc-chm-chu { grid-template-columns: minmax(0, 1fr); }
  .cc-chm-the { padding: 12px; }
  .cc-chm-the__than { grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: start; }
  .cc-chm-vach { width: 88px; height: 30px; }
  .cc-chm-ma { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .cc-chm-the__nut { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 8px; }
  .cc-chm-the__nut .cc-tep__doi { width: auto; justify-content: center; white-space: nowrap; font-size: 14px; padding-left: 4px; padding-right: 4px; }
  .cc-chm-tiep li { padding: 12px; }
}

/* ================= nhóm 2 điện thoại (23/10/2026): tự chấm một câu một màn · lịch lùi chọn nhanh, nhóm gập · nhãn gợi ý từ chữ dán =================
   Màn rộng giữ nguyên bố cục cũ; dải câu và thẻ xong của tự chấm chỉ hiện ở ≤980. */
.cc-tc-dieu, .cc-tc-xong { display: none; }
.cc-tc-xong[hidden] { display: none; }
@media (max-width: 980px) {
  .cc-tc-tien { display: none; }
  .cc-tc-dieu { display: flex; flex-direction: column; gap: 12px; }
  .cc-tc-dieu__dong { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
  .cc-tc-lui { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; padding: 0 4px; border: 0; background: none; font: inherit; font-size: 14px; font-weight: 600; color: var(--text-brand); cursor: pointer; }
  .cc-tc-lui:disabled { color: var(--text-secondary); opacity: 0.5; cursor: default; }
  .cc-tc-dem { font-size: 14px; font-weight: 600; color: var(--text-primary); font-variant-numeric: tabular-nums; }
  .cc-tc-cham { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 0; margin-block: -8px; }
  /* vòng 2 (26/10): vùng chạm cao 44px, mười hai ô liền nhau (khe vẽ bằng lề vạch) */
  .cc-tc-cham button { height: 44px; padding: 0; border: 0; background: none; cursor: pointer; position: relative; }
  .cc-tc-cham button::before { content: ""; position: absolute; left: 2px; right: 2px; top: 20px; height: 4px; border-radius: 2px; background: var(--border-subtle); transition: background var(--dur-base) var(--ease-out); }
  .cc-tc-cham button[data-xong]::before { background: var(--color-studio-blue); }
  .cc-tc-cham button[aria-current]::before { background: var(--brand); top: 18px; height: 8px; border-radius: 4px; }
  .cc-tc-cau > li { display: none; border-bottom: 0; padding-bottom: 0; }
  .cc-tc-cau > li[data-dang] { display: flex; min-height: 168px; animation: cc-tc-vao var(--dur-base) var(--ease-out); }
  .cc-tc-cau[data-xong] { display: none; }
  .cc-tc-cau p { font-size: 16px; }
  .cc-app .cc-tc-nut { grid-template-columns: 1fr; }
  .cc-app .cc-tc-nut button { min-height: 48px; font-size: 15px; }
  .cc-tc-xong { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 8px 12px; padding: 16px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); }
  .cc-tc-xong > i { margin-top: 2px; font-size: 20px; color: var(--text-status-success); }
  .cc-tc-xong p { margin: 0; font-size: 15px; line-height: 1.5; }
  .cc-tc-xong .sv-btn { grid-column: 1 / -1; min-height: 48px; justify-content: center; }
}
@keyframes cc-tc-vao { from { opacity: 0; transform: translateX(12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .cc-tc-cau > li[data-dang] { animation: none; } }

.cc-ll-nhanh { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.cc-ll-nhanh .cc-qh-them__nhan { margin: 0; }
.cc-ll-nhanh__nut { display: flex; flex-wrap: wrap; gap: 8px; }
/* lộ trình theo ngành: mỗi nút hai dòng (tên lộ trình, hợp với ai), xếp dọc để câu dài không gãy nút */
.cc-ll-lo, .cc-mn { flex-direction: column; margin-top: 8px; }
.cc-ll-lo button, .cc-mn button { flex-direction: column; align-items: flex-start; gap: 2px; padding: 8px 14px; text-align: left; }
#cc-kh-nganh, #cc-nc-nganh, #cc-ca-nganh, #cc-cw-nganh, #cc-cm-nganh, #cc-cm-nhanh { max-width: none; }  /* mẫu theo ngành (28/10): tên ngành dài, ô chọn trải hết bề ngang mục */
.cc-ll-lo button span, .cc-mn button span { font-size: 13px; font-weight: 400; line-height: 1.4; color: var(--text-secondary); }
.cc-ll-nhom { border-top: 1px solid var(--hairline); }
.cc-ll-nhom:first-child { border-top: 0; }
.cc-ll-nhom summary { display: flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; list-style: none; }
.cc-ll-nhom summary::-webkit-details-marker { display: none; }
.cc-ll-nhom summary .cc-ca-nhom { margin: 0; flex: 1; min-width: 0; font-size: 14px; letter-spacing: 0; color: var(--text-primary); }
.cc-ll-nhom__dem { font-size: 13px; font-weight: 600; color: var(--text-brand); }
.cc-ll-nhom summary > i { color: var(--text-secondary); transition: transform var(--dur-base) var(--ease-out); }
.cc-ll-nhom[open] summary > i { transform: rotate(180deg); }
.cc-ll-nhom__ruot { display: flex; flex-direction: column; gap: 4px; padding-bottom: 8px; }

.cc-nb-goi[hidden] { display: none; }
.cc-nb-goi ul { margin: 0; }
@media (max-width: 980px) { textarea.cc-nb-chu { min-height: 132px; height: 132px; } }

/* ================= nhóm 3 điện thoại (23/10/2026): gập mục phụ CC.gap =================
   Chỉ ở ≤980: mục mang .cc-vao--gap còn nhãn + dòng tóm, bấm Đổi mới mở ruột. Màn rộng không thấy dòng tóm. */
.cc-vao__tom { display: none; }
@media (max-width: 980px) {
  .cc-vao--gap { gap: 8px; }
  .cc-vao--gap:not([data-mo]) > :not(.cc-vao__nhan):not(.cc-vao__tom) { display: none; }
  .cc-vao--gap[data-mo] { gap: 12px; }
  .cc-vao__tom { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; padding: 0 12px;
    border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); background: var(--surface-card);
    font: inherit; font-size: 14px; color: var(--text-secondary); text-align: left; cursor: pointer; }
  .cc-vao__tom-chu { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .cc-vao__tom-doi { flex: none; display: inline-flex; align-items: center; gap: 4px; font-weight: 600; color: var(--text-brand); }
  .cc-vao__tom-doi i { transition: transform var(--dur-base) var(--ease-out); }
  .cc-vao__tom[aria-expanded="true"] .cc-vao__tom-doi i { transform: rotate(180deg); }
}
@media (prefers-reduced-motion: reduce) { .cc-vao__tom-doi i { transition: none; } }
/* Ô thả tệp ở màn ≤980 (23/10/2026, việc 9): điện thoại không kéo thả, ô cao 148px chỉ để chạm một lần.
   Thu thành một hàng: biểu tượng trái, lời và gợi ý phải, vẫn cao ≥72px cho ngón tay. :not([hidden]) giữ luật ẩn ô. */
@media (max-width: 980px) {
  .cc-app .cc-tha:not([hidden]) { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 12px; row-gap: 2px;
    align-items: center; justify-items: start; min-height: 72px; padding: 12px 16px; text-align: left; }
  .cc-app .cc-tha > i { grid-row: 1 / span 2; font-size: 24px; }
  .cc-app .cc-tha > :not(i) { grid-column: 2; }
  .cc-app .cc-tha > span:empty { display: none; }
}

/* ================= Chế độ ứng dụng ở màn ≤980 (24/10/2026, cong-cu.js UNG_THU) =================
   Hai màn Nhập · Kết quả, thanh chuyển dính đáy trong tầm ngón cái, tấm kéo lên cho mục phụ, ô số có nút bớt thêm.
   Mọi luật neo html.cc-ung (JS chỉ gắn ở màn ≤980), nên màn rộng không đổi. Nhịp một đường cong của hệ (#214). */
html.cc-ung .cc-app[data-man="vao"] > .cc-app__ra,
html.cc-ung .cc-app[data-man="ra"] > .cc-app__vao { display: none; }
html.cc-ung .cc-app > .cc-app__vao, html.cc-ung .cc-app > .cc-app__ra { min-height: 60vh; }
html.cc-ung .cc-may-wrap { padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px)); }
.cc-ung-vao { animation: cc-ung-vao var(--dur-base) var(--ease-out); }
@keyframes cc-ung-vao { from { opacity: 0; transform: translateY(8px); } }
/* thanh điều hướng site thu lên khi cuộn xuống */
html.cc-ung header.nav { transition: transform var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out); }
html.cc-ung.cc-ung--an header.nav { transform: translateY(-100%); }

.cc-thanh { display: none; }
html.cc-ung .cc-thanh { position: fixed; left: 0; right: 0; bottom: 0; z-index: calc(var(--z-sticky) + 1); display: flex; align-items: center; gap: 8px;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px)); background: var(--surface-card); border-top: 1px solid var(--border-subtle);
  box-shadow: 0 -8px 24px -12px color-mix(in srgb, var(--color-deep-navy) 18%, transparent); transition: transform var(--dur-base) var(--ease-out), visibility 0s; }
html.cc-ung .cc-thanh--an { transform: translateY(110%); visibility: hidden; transition: transform var(--dur-base) var(--ease-out), visibility 0s var(--dur-base); }
.cc-thanh__doi { flex: 1; min-width: 0; display: flex; gap: 4px; padding: 4px; border-radius: var(--radius-md); background: var(--surface-sunken); }
.cc-thanh__tab { flex: 1 1 0; min-width: 0; min-height: 48px; display: flex; align-items: center; gap: 8px; padding: 6px 10px; border: 1px solid transparent;
  border-radius: var(--radius-sm); background: transparent; color: var(--text-secondary); font: inherit; text-align: left; cursor: pointer;
  transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out); -webkit-tap-highlight-color: transparent; }
.cc-thanh__tab > i { flex: none; font-size: 20px; }
.cc-thanh__hinh { display: none; flex: none; width: 36px; height: 36px; border-radius: var(--radius-sm); border: 1px solid var(--border-subtle); background: var(--surface-card); object-fit: contain; }
.cc-thanh__tab--hinh .cc-thanh__hinh { display: block; }
.cc-thanh__tab--hinh > i { display: none; }
.cc-thanh__tab[aria-selected="true"] { background: var(--surface-card); border-color: var(--border-subtle); color: var(--text-primary); box-shadow: var(--shadow-xs); }
.cc-thanh__tab[aria-selected="true"] > i { color: var(--text-brand); }
.cc-thanh__tab:active { transform: scale(0.98); }
.cc-thanh__chu { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.cc-thanh__chu b { font-size: 15px; font-weight: 600; white-space: nowrap; }
.cc-thanh__phu, .cc-thanh__phu-o { display: flex; align-items: center; gap: 4px; min-width: 0; font-size: 12px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cc-thanh__phu-o .cc-thanh__phu { display: block; overflow: hidden; text-overflow: ellipsis; }
.cc-thanh__cham { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--text-brand); }
.cc-thanh__cham[hidden] { display: none; }
.cc-thanh[data-muc="tot"] .cc-thanh__cham { background: var(--color-success); }
.cc-thanh[data-muc="vua"] .cc-thanh__cham { background: var(--color-warning); }
.cc-thanh[data-muc="yeu"] .cc-thanh__cham { background: var(--color-danger); }
.cc-thanh[data-muc="tot"] [data-tab="ra"] .cc-thanh__phu { color: var(--text-status-success); }
.cc-thanh[data-muc="vua"] [data-tab="ra"] .cc-thanh__phu { color: var(--text-status-warning); }
.cc-thanh[data-muc="yeu"] [data-tab="ra"] .cc-thanh__phu { color: var(--text-status-critical); }
/* kết quả vừa đổi theo ô khách sửa (đang ở màn Nhập): thẻ Kết quả nháy một nhịp */
.cc-thanh--doi [data-tab="ra"] { animation: cc-thanh-doi var(--dur-slow) var(--ease-out); }
@keyframes cc-thanh-doi { 30% { background: var(--color-warm-cream); color: var(--text-primary); } }
.cc-thanh__chinh { flex: none; min-height: 56px; display: inline-flex; align-items: center; gap: 6px; padding: 0 16px; border: 0; border-radius: var(--radius-md);
  background: var(--color-bordeaux); color: var(--color-white); font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
.cc-thanh__chinh[hidden] { display: none; }
.cc-thanh__chinh i { font-size: 18px; }
.cc-thanh__chinh:active { transform: scale(0.98); }
/* QC 26/10: nút thanh tự báo việc đã xong (chép, tải, in) hay chưa làm được */
.cc-thanh__chinh[data-tt="dang"] { cursor: progress; opacity: 0.85; }
.cc-thanh__chinh[data-tt="xong"] { background: var(--color-success); }
.cc-thanh__chinh[data-tt="loi"] { background: var(--color-danger); }
/* nút chính chiếm chỗ: thẻ Nhập bỏ dòng phụ để chữ thẻ Kết quả không bị cắt (390 với Tải PDF, 360 với mã QR) */
html.cc-ung .cc-thanh:has(.cc-thanh__chinh:not([hidden])) [data-tab="vao"] .cc-thanh__phu { display: none; }
/* Có nút chính thì tab Nhập co về vừa chữ, nhường chỗ cho mức kết luận ở tab Kết quả (không cắt "Nên xem lại"). */
html.cc-ung .cc-thanh:has(.cc-thanh__chinh:not([hidden])) [data-tab="vao"] { flex: 0 0 auto; }
@media (max-width: 640px) { html.cc-ung .cc-thanh:has(.cc-thanh__chinh:not([hidden])) .cc-thanh__tab > i { display: none; } }
@media (max-width: 640px) { .cc-thanh__tab { padding: 6px 8px; gap: 6px; } .cc-thanh__tab > i { font-size: 18px; } .cc-thanh__chinh { padding: 0 12px; } }

/* ô số: nút bớt thêm hai bên, chạm 44px */
/* kiểu "song": ô xem trước dính đầu màn Nhập, chép hình chính; chạm thì sang màn Kết quả */
.cc-ung-xem { display: none; }
html.cc-ung .cc-ung-xem:not([hidden]) { position: sticky; top: var(--cc-ung-tren, 8px); z-index: 2; display: flex; flex-direction: column; align-items: stretch; gap: 8px;
  width: 100%; padding: 12px; border: 1px solid var(--border-subtle); border-radius: var(--radius-md); background: var(--surface-card); box-shadow: var(--shadow-sm);
  color: var(--text-secondary); font: inherit; text-align: left; cursor: pointer; transition: top var(--dur-base) var(--ease-out); }
.cc-ung-xem__ruot { display: flex; align-items: center; justify-content: center; max-height: 28vh; max-height: 28svh; overflow: hidden; pointer-events: none; }
.cc-ung-xem__ruot > * { max-width: 100%; max-height: 28vh; max-height: 28svh; }
.cc-ung-xem__ruot > img { object-fit: contain; }
.cc-ung-xem__chu { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 13px; }
.cc-ung-xem:active { transform: scale(0.99); }
/* dòng xem mẫu đầu màn Nhập cho công cụ không có sẵn dòng ấy trong bảng nhập */
.cc-ung-mau { display: none; }
html.cc-ung .cc-ung-mau:not([hidden]) { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 48px; padding: 12px 16px; border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md); background: var(--surface-page); color: var(--text-brand); font: inherit; font-weight: 600; text-align: left; cursor: pointer; }
html.cc-ung .cc-ung-mau i { font-size: 18px; }
html.cc-ung .cc-ung-mau:active { transform: scale(0.99); }
.cc-ung-so { display: none; }
html.cc-ung .cc-ung-so { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0;
  border: 1px solid var(--border-subtle); border-radius: var(--radius-sm); background: var(--surface-card); color: var(--text-primary); font-size: 18px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
html.cc-ung .cc-ung-so:active { background: var(--surface-sunken); transform: scale(0.96); }
html.cc-ung .cc-qr-so { gap: 6px; }
html.cc-ung .cc-qr-so .cc-o { max-width: 72px; min-height: 44px; text-align: center; }

/* tấm kéo lên cho mục gập */
.cc-tam-goc { position: fixed; inset: 0; z-index: var(--z-modal); }
.cc-tam-nen { position: absolute; inset: 0; background: color-mix(in srgb, var(--color-deep-navy) 45%, transparent); opacity: 0; transition: opacity var(--dur-base) var(--ease-out); }
.cc-tam { position: absolute; left: 0; right: 0; bottom: 0; max-height: 85vh; max-height: 85dvh; display: flex; flex-direction: column;
  background: var(--surface-card); border-radius: var(--radius-lg) var(--radius-lg) 0 0; padding-bottom: env(safe-area-inset-bottom, 0px);
  transform: translateY(100%); transition: transform var(--dur-base) var(--ease-out); }
.cc-tam-goc--mo .cc-tam-nen { opacity: 1; }
.cc-tam-goc--mo .cc-tam { transform: none; }
.cc-tam__dau { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 20px 12px; border-bottom: 1px solid var(--hairline); touch-action: none; }
.cc-tam__keo { position: absolute; top: 8px; left: 50%; width: 40px; height: 4px; margin-left: -20px; border-radius: var(--radius-pill); background: var(--border-strong); }
.cc-tam:focus { outline: none; }
/* hình kết quả ở đầu tấm: khách đổi màu, kiểu ô vẫn thấy mã đổi theo dù tấm che bàn */
.cc-tam__hinh { flex: none; width: 56px; height: 56px; border-radius: var(--radius-sm); border: 1px solid var(--border-subtle); background: var(--surface-card); object-fit: contain; }
.cc-tam__hinh[hidden] { display: none; }
.cc-tam__ten { flex: 1; min-width: 0; margin: 0; font-family: var(--font-heading); font-weight: 600; font-size: 18px; color: var(--text-primary); }
.cc-tam__xong { min-height: 44px; }
.cc-tam__than { overflow-y: auto; overscroll-behavior: contain; padding: 16px 20px 24px; }
@media (prefers-reduced-motion: reduce) {
  .cc-ung-vao, .cc-thanh--doi [data-tab="ra"] { animation: none; }
  html.cc-ung header.nav, html.cc-ung .cc-thanh, .cc-tam, .cc-tam-nen { transition-duration: 0.001ms; }
}

/* Hệ trạng thái #221: nút đang chờ máy không mờ như nút tắt; dòng tiến trình có vòng quay trước chữ */
button[data-tt~="dang"]:disabled { opacity: 1; cursor: progress; }
.cc-goi-y[data-tt~="dang"]::before {
  content: ""; display: inline-block; width: 12px; height: 12px; margin-right: 8px; vertical-align: -1px;
  border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent;
  animation: tt-quay .7s linear infinite;
}
@media (prefers-reduced-motion: reduce) { .cc-goi-y[data-tt~="dang"]::before { animation: none; } }

/* Chạm có phản hồi trên điện thoại (26/10/2026, anh báo: nút không nhún nên chạm lần hai rồi mất phần đang làm).
   Mọi nút, ô thả tệp của bàn làm việc nhún nhẹ khi ngón tay đặt xuống; touch-action manipulation bỏ phóng to
   khi chạm đúp (chạm đúp từng làm màn nhảy, ngón tay rơi nhầm chỗ). :where giữ độ ưu tiên 0, nút nào đã có
   nhún riêng thì luật riêng thắng. iOS chỉ bật :active khi trang nghe touchstart (cong-cu.js). */
:where(.cc-app, .cc-tam, .cc-thanh) :where(button, .cc-tha, summary, a) { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
:where(.cc-app, .cc-tam) :where(button:not(:disabled), .cc-tha, summary):active { transform: scale(.97); transition: transform 60ms var(--ease-out); }
@media (prefers-reduced-motion: reduce) { :where(.cc-app, .cc-tam) :where(button, .cc-tha, summary):active { transform: none; } }
/* dòng báo đã mở lại phần làm dở: đứng đầu bảng nhập */
.cc-ghi-do.cc-giu { margin: 0 0 16px; align-items: baseline; }
.cc-giu .cc-tep__doi { white-space: nowrap; }
