/* doankimtiep (Sổ Bảo Trì NMG2): components the kit lacks and layout glue. Values come from tokens only. */

/* ---- Equipment record: many short label / value pairs in as many columns as fit (KIT_GAPS 1) ---- */
.dkt-spec { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr)); column-gap: var(--sp-6); margin: 0; }
.dkt-spec > div { display: grid; grid-template-columns: minmax(0, 9.5rem) minmax(0, 1fr); gap: var(--sp-3); align-content: start; padding: var(--sp-2) 0; border-bottom: 1px solid var(--panel-border); }
.dkt-spec dt { color: var(--muted); font-size: var(--fs-sm); }
.dkt-spec dd { margin: 0; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
/* PLC addresses are one long mono code each: the label goes above the value, so the code keeps one line inside its column (KIT_GAPS 1) */
.dkt-spec-code > div { grid-template-columns: minmax(0, 1fr); gap: 0; }

/* ---- Facts of a task set, in one line that wraps ---- */
.dkt-facts { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-7); margin: 0 0 var(--sp-3); }
.dkt-facts dt { color: var(--muted); font-size: var(--fs-sm); }
.dkt-facts dd { margin: 0; font-weight: 600; }

/* ---- Photo slots of the record, and the drawings that stand in for photos (KIT_GAPS 2) ---- */
.dkt-photos { display: grid; gap: var(--sp-4); }
.dkt-art { width: 100%; height: 100%; max-height: 100%; }
.dkt-mini { display: inline-block; width: 3rem; height: 2.25rem; margin-right: var(--sp-1); color: var(--muted); background: var(--sunk); border-radius: var(--radius-sm); vertical-align: middle; }

/* ---- Text glue ---- */
.dkt-h3 { margin: 0; font-size: var(--fs-md); }
.dkt-sub { display: block; color: var(--muted); font-size: var(--fs-sm); }
.dkt-small { font-size: var(--fs-xs); }
.dkt-title { margin: 0; font-size: var(--fs-lg); font-weight: 700; line-height: var(--lh-tight); }
.dkt-section { display: flex; align-items: center; gap: var(--sp-2); margin: 0; font-size: var(--fs-xl); }
.dkt-bad { color: var(--danger); }
.dkt-warn { color: var(--warn); }
.dkt-wrap { font-weight: 600; }
.dkt-grpname { font-weight: 400; }
.dkt-bullets { margin: 0; padding-left: var(--sp-5); color: var(--muted); }
.dkt-summary { margin: 0; }

/* ---- Layout glue ---- */
.dkt-start { align-self: flex-start; }
.dkt-end { align-self: flex-end; }
.dkt-foot-start { margin-right: auto; }
.dkt-narrow { max-width: 56rem; }
.dkt-w-sm { width: 13rem; }
.dkt-qty { width: 8rem; }
.dkt-gan { --tbl-max-h: 30rem; }
.dkt-hit { display: inline-flex; align-items: center; min-height: var(--tap); }
/* A link inside a phone sentence: the padding of an inline box widens the hit area to --tap without moving the text (KIT_GAPS 37) */
.dkt-tap-inline { position: relative; z-index: 1; padding-block: var(--sp-4); }
.dkt-checks { display: grid; gap: var(--sp-1); margin: 0; padding: 0; list-style: none; }
.dkt-checks .check { min-height: var(--tap); }

/* ---- Phone sign-in: the page fills the screen; the drawing gives the tinted top its height ---- */
.dkt-fill { height: 100dvh; }
.dkt-login-art { width: min(100%, 14rem); height: 12rem; margin-top: var(--sp-6); color: var(--muted); }

/* ---- Calendar: the line that stands for the daily jobs of a day (KIT_GAPS 3) ---- */
.dkt-daily { padding: 0 var(--sp-1); color: var(--muted); font-size: var(--fs-xs); }

/* ---- Paper: header box Mã số / Lần BH / Ngày HL / Trang, key-value blocks, plan grid (KIT_GAPS 4) ---- */
.dkt-printhead { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: var(--sp-3) var(--sp-5); padding: var(--sp-4); border: 1px solid var(--field-border); }
.dkt-printhead-org { font-weight: 700; text-transform: uppercase; }
.dkt-printhead-title { grid-column: 1; font-weight: 700; }
.dkt-printhead > .dkt-printhead-box { grid-column: 2; grid-row: 1 / span 2; }
.dkt-printhead-box { flex: none; min-width: 12rem; margin: 0; border-top: 1px solid currentColor; border-left: 1px solid currentColor; }
.dkt-printhead-box > div { display: grid; grid-template-columns: 5rem 1fr; border-right: 1px solid currentColor; border-bottom: 1px solid currentColor; }
.dkt-printhead-box dt { padding: 0 var(--sp-2); border-right: 1px solid currentColor; }
.dkt-printhead-box dd { margin: 0; padding: 0 var(--sp-2); }
.dkt-pblock { margin-top: var(--sp-3); }
.dkt-ph { margin: 0 0 var(--sp-1); font-family: inherit; font-size: inherit; font-weight: 700; text-transform: uppercase; break-after: avoid; }
.dkt-kv th { width: 19%; }
.dkt-kv td { width: 31%; overflow-wrap: anywhere; }
.dkt-pfig { width: 18rem; margin: 0; padding: var(--sp-2); text-align: center; border: 1px solid currentColor; break-inside: avoid; }
.dkt-legend { margin: var(--sp-3) 0 0; }
.dkt-p3-name { width: 24%; }
