/* Khu điền thông tin cho hai tài liệu bán hàng.
 *
 * Chỉ sống trên màn hình. Bản in phải sạch như thể tài liệu vốn được soạn sẵn
 * với đúng những con số ấy — không viền, không nút, không dấu vết của form.
 */

/* ---------- Ô placeholder trên trang ---------- */
[data-fill] {
  border-radius: 3px;
  transition: background-color .15s;
}
/* Chưa điền: nền vàng nhạt để người soạn thấy ngay còn thiếu chỗ nào. */
[data-fill].is-empty {
  background: #FFF3CD;
  box-shadow: 0 0 0 2px #FFF3CD;
  cursor: pointer;
}
[data-fill].is-empty:hover {
  background: #FFE69C;
  box-shadow: 0 0 0 2px #FFE69C;
}
/* Vừa điền xong: nháy xanh một cái rồi tắt. */
[data-fill].just-set {
  animation: nhl-flash 1.1s ease-out;
}
@keyframes nhl-flash {
  from { background: #C9F2DC; box-shadow: 0 0 0 2px #C9F2DC; }
  to   { background: transparent; box-shadow: none; }
}

/* ---------- Nút trên thanh điều hướng ---------- */
.nhl-bar .nhl-fill {
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 999px;
  padding: .32rem .85rem;
  cursor: pointer;
  font: inherit;
  color: inherit;
  background: none;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
}
.nhl-bar .nhl-fill:hover { background: #fff; color: #111; border-color: #fff; }
.nhl-bar .nhl-fill.is-todo { background: #E9973F; border-color: #E9973F; color: #fff; }
.nhl-bar .nhl-fill.is-todo:hover { background: #F2A85C; border-color: #F2A85C; color: #fff; }
.nhl-bar .nhl-fill b { font-weight: 600; }

/* ---------- Lớp phủ ---------- */
.nhl-ov {
  position: fixed;
  inset: 0;
  background: rgba(12, 22, 32, .55);
  backdrop-filter: blur(2px);
  z-index: 9998;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 3vh 4vw;
  overflow: auto;
}
.nhl-ov[hidden] { display: none; }

.nhl-modal {
  background: #fff;
  color: #1B2733;
  width: min(760px, 100%);
  border-radius: 14px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .35);
  font: 14px/1.5 "Helvetica Neue", "Segoe UI", system-ui, Arial, sans-serif;
  overflow: hidden;
}

.nhl-modal header {
  padding: 18px 22px 14px;
  border-bottom: 1px solid #E4EAF0;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.nhl-modal header h2 { font-size: 17px; font-weight: 700; color: #0E3A5C; margin: 0 0 3px; }
.nhl-modal header p { font-size: 12.5px; color: #5C6B7A; margin: 0; }
.nhl-modal header button {
  margin-left: auto;
  border: 0;
  background: none;
  font-size: 26px;
  line-height: 1;
  color: #8A99A8;
  cursor: pointer;
  padding: 0 2px;
}
.nhl-modal header button:hover { color: #1B2733; }

.nhl-body { padding: 6px 22px 4px; max-height: 62vh; overflow: auto; }

.nhl-group { padding: 14px 0; border-bottom: 1px solid #EEF2F6; }
.nhl-group:last-child { border-bottom: 0; }
.nhl-group > h3 {
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #E9973F;
  font-weight: 700;
  margin: 0 0 10px;
}
.nhl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.nhl-grid.one { grid-template-columns: 1fr; }

.nhl-f { display: flex; flex-direction: column; gap: 4px; }
.nhl-f.wide { grid-column: 1 / -1; }
.nhl-f label { font-size: 12px; color: #5C6B7A; }
.nhl-f .in { position: relative; display: flex; align-items: center; }
.nhl-f input {
  width: 100%;
  border: 1px solid #D3DDE7;
  border-radius: 7px;
  padding: 8px 10px;
  font: inherit;
  color: #1B2733;
  background: #fff;
}
.nhl-f input:focus { outline: 0; border-color: #0E3A5C; box-shadow: 0 0 0 3px rgba(14, 58, 92, .12); }
.nhl-f input.money { text-align: right; padding-right: 34px; font-variant-numeric: tabular-nums; }
.nhl-f .unit {
  position: absolute;
  right: 11px;
  font-size: 12px;
  color: #8A99A8;
  pointer-events: none;
}

.nhl-split { display: flex; gap: 8px; align-items: center; margin-top: 9px; }
.nhl-mini {
  border: 1px solid #D3DDE7;
  background: #F4F7FA;
  border-radius: 7px;
  padding: 6px 11px;
  font: inherit;
  font-size: 12.5px;
  color: #0E3A5C;
  cursor: pointer;
}
.nhl-mini:hover { background: #E8EFF5; border-color: #B9C8D6; }
.nhl-split span { font-size: 12px; color: #8A99A8; }

.nhl-modal footer {
  padding: 14px 22px 18px;
  border-top: 1px solid #E4EAF0;
  display: flex;
  align-items: center;
  gap: 10px;
  background: #FAFCFD;
}
.nhl-left { font-size: 12.5px; color: #5C6B7A; margin-right: auto; }
.nhl-left b { color: #C1740E; }
.nhl-btn {
  border: 1px solid #D3DDE7;
  background: #fff;
  border-radius: 8px;
  padding: 9px 16px;
  font: inherit;
  cursor: pointer;
  color: #1B2733;
}
.nhl-btn:hover { background: #F0F4F8; }
.nhl-btn.pri { background: #0E3A5C; border-color: #0E3A5C; color: #fff; font-weight: 600; }
.nhl-btn.pri:hover { background: #092740; }
.nhl-btn.ghost { border-color: transparent; color: #8A99A8; }
.nhl-btn.ghost:hover { color: #B4342B; background: #FDF1F0; }

@media (max-width: 640px) {
  .nhl-grid { grid-template-columns: 1fr; }
  .nhl-modal footer { flex-wrap: wrap; }
  .nhl-left { width: 100%; margin: 0 0 4px; }
}

/* Bản in không có gì của khu này. */
@media print {
  .nhl-ov, .nhl-bar .nhl-fill { display: none !important; }
  [data-fill], [data-fill].is-empty, [data-fill].just-set {
    background: none !important;
    box-shadow: none !important;
    animation: none !important;
  }
}
