/* Chấm thi nhiều giám khảo (app/cong-cu/cham-thi.php). Tệp nạp ở MỌI trang → mọi lớp tiền tố cth-. Chỉ dùng token của app.css. */
.chinh:has(> #cth-gv), .chinh:has(.cth-bang) { max-width: 1200px; }
.cth-muc__ten { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cth-muc__ten a { color: var(--chu); text-decoration: none; }
.cth-muc__ten a:hover { color: var(--c-dam); }

/* Soạn tiêu chí */
.cth-tc { display: grid; gap: 10px; margin-bottom: 10px; }
.cth-tc__dong { border: 1px solid var(--vien); border-radius: var(--r-nho); padding: 10px 12px 12px; margin: 0; display: grid; gap: 10px;
  grid-template-columns: 1fr 1fr; }
.cth-tc__dong legend { font-weight: 700; font-size: .875rem; color: var(--phu); padding: 0 4px; }
.cth-tc__dong--loi { border-color: var(--do); }
.cth-tc__ten, .cth-tc__mt { grid-column: 1 / -1; }
.cth-tc__dong > .field__err { grid-column: 1 / -1; }
@media (min-width: 800px) {
  .cth-tc__dong { grid-template-columns: minmax(0, 2fr) 110px 100px minmax(0, 2fr); }
  .cth-tc__ten, .cth-tc__mt { grid-column: auto; }
}
.cth-tom-tc { margin: 0 0 8px; padding-left: 1.4em; }
.cth-tom-tc li { margin-bottom: 4px; }

/* Bảng */
.cth-bang-cuon { overflow-x: auto; margin-bottom: 8px; }
.cth-bang { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.cth-bang th, .cth-bang td { padding: 8px; border-bottom: 1px solid var(--vien); text-align: left; vertical-align: middle; }
.cth-bang thead th { font-size: .8125rem; color: var(--phu); white-space: nowrap; }
.cth-bang tbody th { font-weight: 600; }
.cth-bang .so { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cth-bang input:not([type="checkbox"]) { width: 100%; min-width: 7em; min-height: 40px; padding: 6px 10px; border: 1px solid #cfd6d1; border-radius: var(--r-nho); font: inherit; }
.cth-bang input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--do); }
.cth-bang .cth-o-stt { min-width: 3.5em; width: 4.2em; text-align: center; }
.cth-giua { text-align: center !important; }
.cth-co-giai td:first-child, .cth-co-giai td:nth-child(3) { font-weight: 700; color: var(--nhan-dam); }
.cth-bo { text-decoration: line-through; color: var(--phu); }
.cth-o-xong { color: var(--xanh-la); }
.cth-o-thieu { color: var(--nhan-dam); font-size: .8125rem; font-weight: 700; }
.cth-ma { font-family: ui-monospace, Menlo, Consolas, monospace; font-weight: 800; letter-spacing: .1em; background: var(--c-nhat); color: var(--c-dam);
  padding: 1px 8px; border-radius: 6px; margin-left: 6px; }
.cth-ct summary { cursor: pointer; }
.cth-ct[open] summary { margin-bottom: 10px; }
.cth-nx { margin: 0; padding-left: 1.2em; }

/* Phòng */
.cth-phong { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.cth-phong__chu { flex: 1 1 260px; min-width: 0; }
.cth-phong__ma { font-size: clamp(2.4rem, 10vw, 3.4rem); font-weight: 900; letter-spacing: .14em; color: var(--c-dam); font-variant-numeric: tabular-nums; line-height: 1.2; margin: 4px 0 8px; }
.cth-qr { flex: none; width: 150px; background: #fff; line-height: 0; }
.cth-qr svg, .cth-the-ma__qr svg { width: 100%; height: auto; display: block; }
.cth-goi-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: end; }
.cth-goi-form .field { flex: 1 1 240px; }

/* Giám khảo (điện thoại) */
.cth-o-ma { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 1.5rem !important; letter-spacing: .2em; text-transform: uppercase; text-align: center; font-weight: 800; }
.cth-gk-dau { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 10px; }
.cth-gk-dau h1 { margin: 0; }
.cth-goi { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; background: var(--nhan-nhat); border: 1px solid #f3d49b; border-radius: var(--r);
  padding: 12px 14px; margin-bottom: 12px; }
.cth-goi span { font-size: .8125rem; font-weight: 700; color: var(--nhan-dam); text-transform: uppercase; letter-spacing: .04em; flex: 1 0 100%; }
.cth-goi strong { flex: 1; font-size: 1.125rem; }
.cth-ds-ts { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cth-ts { display: flex; align-items: center; gap: 12px; background: var(--the); border: 1px solid var(--vien); border-radius: var(--r); padding: 12px 14px;
  text-decoration: none; color: var(--chu); min-height: 60px; }
.cth-ts:hover { border-color: var(--c-vien); }
.cth-ts--goi { border: 2px solid var(--nhan); }
.cth-ts__stt { flex: none; display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--c-nhat); color: var(--c-dam); font-weight: 800; }
.cth-ts__ten { flex: 1; min-width: 0; font-weight: 700; }
.cth-ts__ten small { display: block; font-weight: 400; color: var(--phu); font-size: .8125rem; }
.cth-ts__tt { flex: none; }
.cth-ghi { font-size: .9375rem; }
.cth-ghi p:last-child { margin: 0; }
.cth-cham-dau h1 { margin: 2px 0; }
.cth-o { margin-bottom: 10px; }
.cth-o__ten { display: block; font-weight: 700; margin-bottom: 6px; }
.cth-o__ten .phu { font-weight: 400; font-size: .875rem; }
.cth-o__nhap { display: flex; align-items: center; gap: 10px; }
.cth-o__so { width: 7.5em; min-height: 52px; padding: 8px 12px; border: 1px solid #cfd6d1; border-radius: var(--r-nho); font: inherit; font-size: 1.5rem; font-weight: 800;
  text-align: center; font-variant-numeric: tabular-nums; }
.cth-o__so:focus { border-color: var(--c); outline: 3px solid var(--c-nhat); }
.cth-o__so--sai, .cth-o--loi .cth-o__so { border-color: var(--do); background: var(--do-nhat); }
.cth-o__tren { font-size: 1.125rem; color: var(--phu); font-weight: 700; }
.cth-tam-tinh { font-weight: 700; color: var(--c-dam); margin: 4px 0 0; min-height: 1.5em; }

/* Phiếu mã giám khảo để in */
.cth-phieu-ma { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.cth-the-ma { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px dashed #9aa6a8; border-radius: 10px; padding: 14px; break-inside: avoid; }
.cth-the-ma__qr { flex: none; width: 120px; line-height: 0; }
.cth-the-ma p { margin: 0 0 4px; }
.cth-the-ma__ct { font-weight: 700; color: var(--c-dam); }
.cth-the-ma__so { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 1.2rem; letter-spacing: .12em; }
@media print {
  .che-do-gv .dau, .che-do-gv .demo-bar, .che-do-gv .chan, .cth-khong-in, .cth-ct:not([open]) { display: none !important; }
  .cth-phieu-ma { grid-template-columns: 1fr 1fr; }
  .tieu-de-trang .hang-nut { display: none; }
}

/* Màn chiếu */
.cth-chieu { min-height: calc(100vh - 48px); display: flex; flex-direction: column; }
.cth-c-ve { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 1.2vh; padding-bottom: 70px; }
.cth-c-ten { font-size: clamp(1.1rem, 2vw, 1.8rem); font-weight: 700; opacity: .85; margin: 0 0 3vh; }
.cth-c-nho { font-size: clamp(1rem, 1.8vw, 1.6rem); text-transform: uppercase; letter-spacing: .12em; color: var(--nhan); margin: 0; font-weight: 800; }
.cth-c-so { font-size: clamp(3rem, 9vw, 8rem); font-weight: 900; color: var(--nhan); margin: 0; line-height: 1; }
.cth-c-lon { font-size: clamp(2rem, 5.5vw, 5rem); font-weight: 900; margin: 0; line-height: 1.15; }
.cth-c-phu { font-size: clamp(1rem, 2vw, 1.7rem); opacity: .85; margin: 0; }
.cth-c-tien { width: min(720px, 80vw); height: 14px; border-radius: 999px; background: rgba(255,255,255,.18); overflow: hidden; margin-top: 4vh; }
.cth-c-tien span { display: block; height: 100%; background: var(--nhan); border-radius: inherit; transition: width .6s; }
.cth-c-h { font-size: clamp(1.8rem, 3.6vw, 3.2rem); margin: 0 0 2vh; }
.cth-c-giai-ten { font-size: clamp(2.4rem, 6vw, 5.4rem); font-weight: 900; color: var(--nhan); margin: 0 0 3vh; }
.cth-c-dat { display: flex; flex-wrap: wrap; justify-content: center; gap: 2vw; }
.cth-c-nguoi { background: rgba(255,255,255,.1); border: 2px solid var(--nhan); border-radius: 18px; padding: 2.4vh 2.6vw; min-width: min(360px, 80vw);
  display: flex; flex-direction: column; gap: .6vh; animation: cth-hien .7s ease-out both; }
.cth-c-nguoi strong { font-size: clamp(1.6rem, 3.4vw, 3rem); line-height: 1.2; }
.cth-c-nguoi span { font-size: clamp(1rem, 1.6vw, 1.4rem); opacity: .85; }
.cth-c-nguoi em { font-style: normal; font-size: clamp(1.1rem, 2vw, 1.8rem); color: var(--nhan); font-weight: 800; }
.cth-c-cu { margin-top: 4vh; font-size: clamp(1rem, 1.6vw, 1.4rem); opacity: .85; }
.cth-c-cu p { margin: 0 0 .6vh; }
.cth-c-cu span { color: var(--nhan); font-weight: 700; }
.cth-c-bang { width: min(1300px, 94vw); max-height: 72vh; overflow: auto; }
.cth-c-bang table { width: 100%; border-collapse: collapse; font-size: clamp(1rem, 1.7vw, 1.6rem); text-align: left; }
.cth-c-bang th, .cth-c-bang td { padding: 1vh 1vw; border-bottom: 1px solid rgba(255,255,255,.2); }
.cth-c-bang th { font-size: .75em; opacity: .8; }
.cth-c-bang .so { text-align: right; font-variant-numeric: tabular-nums; }
.cth-c-bang small { display: block; opacity: .8; font-size: .7em; }
.cth-c-giai td { color: var(--nhan); font-weight: 800; }
.cth-c-dk { position: fixed; left: 12px; right: 12px; bottom: 12px; display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; opacity: .35; transition: opacity .2s; }
.cth-c-dk:hover, .cth-c-dk:focus-within { opacity: 1; }
.cth-c-nut { font: inherit; font-size: .875rem; font-weight: 700; min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1px solid rgba(255,255,255,.5);
  background: rgba(0,0,0,.25); color: #fff; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; }
.cth-c-nut:hover { background: rgba(255,255,255,.15); }
@keyframes cth-hien { from { opacity: 0; transform: translateY(16px) scale(.96); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .cth-c-nguoi { animation: none; } }
