/* Phân hệ Hoạt động cho con + Lịch. Chỉ dùng token của app.css. Lớp tiền tố hd- (hoạt động) và lich- (lịch). */

.an-chu { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Thẻ hoạt động trong danh sách */
a.hd-the { display: flex; gap: 14px; align-items: flex-start; }
.hd-the__ngay { flex: none; width: 52px; padding: 6px 0; border-radius: var(--r-nho); background: var(--c-nhat); color: var(--c-dam);
  display: flex; flex-direction: column; align-items: center; line-height: 1.1; }
.hd-the__thu { font-size: 1.375rem; font-weight: 800; }
.hd-the__thang { font-size: .75rem; font-weight: 700; text-transform: uppercase; }
.hd-the__than { flex: 1; min-width: 0; }
.hd-the__ten { font-size: 1.0625rem; margin: 0 0 4px; }
.hd-the__dong { display: flex; gap: 6px; align-items: flex-start; margin: 0 0 2px; color: var(--phu); font-size: .9375rem; }
.hd-the__dong .bt { flex: none; margin-top: 3px; }
.hd-the__nhan { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 0; }
.hd-the__nhan:empty { display: none; }
.hd-the--huy .hd-the__ngay { background: #eef0ed; color: var(--phu); }
.hd-the--huy .hd-the__ten { text-decoration: line-through; color: var(--phu); }
.hd-cho { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.hd-cho .thanh-tien { flex: 1; max-width: 220px; }

/* Chi tiết */
.hd-tt { margin: 0; display: grid; gap: 10px; }
.hd-tt > div { display: flex; gap: 10px; align-items: flex-start; }
.hd-tt dt { flex: none; color: var(--c); padding-top: 2px; }
.hd-tt dd { margin: 0; flex: 1; min-width: 0; }
.hd-mo-ta { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--vien); }
.hd-mo-ta p:last-child { margin-bottom: 0; }
.hd-ghi-chu { margin-top: 4px; padding: 4px 10px; border-radius: var(--r-nho); background: var(--nhan-nhat); color: var(--nhan-dam); }
#viec .ds__muc { align-items: center; }

/* Lịch: đầu trang */
.lich-dau { display: flex; align-items: center; gap: 4px; margin: 4px 0 12px; }
.lich-dau h1 { margin: 0 2px; font-size: 1.25rem; min-width: 7.5em; text-align: center; white-space: nowrap; }
.lich-dau__nay { margin-left: auto; white-space: nowrap; }

/* Lưới tháng — điện thoại: ô nhỏ, số ngày + chấm */
.the.lich { padding: 10px; }
.lich-luoi__hang { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; }
.lich-luoi__thu { text-align: center; font-size: .75rem; font-weight: 700; color: var(--phu); padding: 4px 0 6px; }
.lich-o { min-height: 46px; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 4px 0; border-radius: var(--r-nho); }
.lich-o__so { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; font-size: .9375rem; color: var(--chu); text-decoration: none; }
a.lich-o__so { font-weight: 700; background: var(--bg); }
a.lich-o__so:hover { background: var(--c-nhat); color: var(--c-dam); }
.lich-o--cuoi-tuan .lich-o__so { color: var(--phu); }
.lich-o--cuoi-tuan a.lich-o__so { color: var(--chu); }
.lich-o--nay .lich-o__so, .lich-o--nay a.lich-o__so { background: var(--c); color: #fff; font-weight: 800; }
.lich-o__cham { display: flex; gap: 3px; }
.lich-o__ds { display: none; }
.lich-cham { display: inline-block; flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.lich-cham--han { background: var(--nhan); }
.lich-cham--ks { background: var(--do); }
.lich-chu-giai { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 10px 4px 2px; }
.lich-chu-giai span { display: inline-flex; align-items: center; gap: 6px; }

/* Danh sách theo ngày (điện thoại) */
.lich-ngay { scroll-margin-top: 80px; }
.lich-ngay h2 { font-size: 1rem; margin-bottom: 4px; }
.lich-ngay .ds__muc { align-items: baseline; padding: 10px 0; }
.lich-ngay .lich-cham { width: 10px; height: 10px; }
.lich-ngay--nay { border-color: var(--c-vien); box-shadow: inset 4px 0 0 var(--c), var(--bong); }

/* Máy tính: lưới 7 cột có tên sự kiện, bỏ danh sách theo ngày */
@media (min-width: 900px) {
  .the.lich { padding: 14px; }
  .lich-luoi__hang { gap: 0; }
  .lich-luoi__hang + .lich-luoi__hang .lich-o { border-top: 1px solid var(--vien); }
  .lich-o { min-height: 108px; align-items: stretch; padding: 6px; border-radius: 0; border-left: 1px solid var(--vien); }
  .lich-o:first-child { border-left: 0; }
  .lich-o--rong { background: var(--bg); }
  .lich-o--nay { background: var(--c-nhat); }
  .lich-o__so, a.lich-o__so { width: 28px; height: 28px; font-size: .875rem; background: transparent; pointer-events: none; }
  .lich-o__cham { display: none; }
  .lich-o__ds { display: flex; flex-direction: column; gap: 3px; list-style: none; margin: 2px 0 0; padding: 0; }
  .lich-sk a { display: block; padding: 2px 6px; border-radius: 6px; font-size: .75rem; line-height: 1.35; text-decoration: none;
    background: var(--c-nhat); color: var(--c-dam); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; word-break: break-word; }
  .lich-sk--han a { background: var(--nhan-nhat); color: var(--nhan-dam); }
  .lich-sk--ks a { background: var(--do-nhat); color: var(--do); }
  .lich-sk--huy a { text-decoration: line-through; opacity: .7; }
  .lich-sk a:hover { box-shadow: inset 0 0 0 1px currentColor; }
  .lich-ngay { display: none; }
}
