

.tk-toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.tk-input {
  font-family: inherit; font-size: 13px; padding: 8px 11px;
  border: 1px solid #cfd6de; border-radius: 6px; background: #fff; color: #213040;
  outline: none; transition: border-color .15s, box-shadow .15s;
}
.tk-input:focus { border-color: var(--tk-blue, #1a6bbf); box-shadow: 0 0 0 3px rgba(26,107,191,.12); }
.tk-hint { color: #7a8694; font-size: 12.5px; padding: 8px 2px; }
.tk-empty { text-align: center; color: #9aa6b2; padding: 36px 12px; font-size: 13px; }
.tk-empty i { font-size: 26px; display: block; margin-bottom: 8px; color: #c3ccd5; }
.tk-btn {
  font-family: inherit; font-size: 12.5px; font-weight: 700; padding: 9px 16px;
  border-radius: 6px; cursor: pointer; border: 1px solid transparent; transition: all .15s;
}
.tk-btn:disabled { opacity: .55; cursor: default; }
.tk-btn-primary { background: var(--tk-blue, #1a6bbf); color: #fff; }
.tk-btn-primary:hover:not(:disabled) { background: #155a9f; }
.tk-lint { padding: 8px 12px; border-radius: 8px; font-size: 13px; line-height: 1.45; min-height: 24px; }
.tk-lint-do { background: #fdecea; color: #b02a1e; border: 1px solid #f5c6c0; }


.bt-toolbar { align-items: center; gap: 12px }
.bt-wrap { display: flex; gap: 10px; align-items: stretch; min-height: 420px }
.bt-panel { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; position: relative;
  background: var(--card, #fff); border: 1px solid var(--border, #d7dce3); border-radius: 10px; overflow: hidden }
.bt-panel-hd { display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 8px 10px; background: var(--thead, #f2f5f9); border-bottom: 1px solid var(--border, #d7dce3);
  cursor: grab; user-select: none }
.bt-panel-hd:active { cursor: grabbing }
.bt-panel-title { font-weight: 700; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.bt-panel-acts { display: flex; gap: 4px; flex-shrink: 0 }
.bt-ico { border: 1px solid var(--border, #d7dce3); background: #fff; border-radius: 6px;
  min-width: 32px; min-height: 32px; cursor: pointer; font-size: 13px; line-height: 1 }
.bt-ico:hover { background: #eef3fa }
.bt-ico:disabled { opacity: .35; cursor: default }
.bt-ico:disabled:hover { background: #fff }
.bt-panel-search { display: flex; gap: 6px; padding: 8px 10px; border-bottom: 1px solid var(--border, #d7dce3) }
.bt-panel-search .bt-in { flex: 1; min-width: 0 }

.bt-disc { font-size: 11px; line-height: 1.4; color: #8a6d1a; background: #fffbea;
  border-bottom: 1px solid #f0dfa0; padding: 6px 10px }
.bt-panel-bd { flex: 1; overflow: auto; padding: 10px; max-height: calc(100vh - 250px) }
.bt-sec-title { font-weight: 700; margin: 6px 0 8px; font-size: 13px; color: var(--muted, #555) }
.bt-recent { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px }
.bt-chip { border: 1px solid var(--border, #d7dce3); background: #fff; border-radius: 16px;
  padding: 6px 12px; min-height: 32px; cursor: pointer; font-size: 12px; max-width: 100%;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.bt-chip:hover { background: #eef3fa }
.bt-chapters { display: flex; flex-direction: column; gap: 4px }
.bt-chap { display: flex; align-items: center; gap: 8px; text-align: left; width: 100%;
  border: 1px solid var(--border, #d7dce3); background: #fff; border-radius: 8px;
  padding: 8px 10px; min-height: 44px; cursor: pointer }
.bt-chap:hover { background: #eef3fa }
.bt-chap-no { background: #1a4b8c; color: #fff; border-radius: 6px; min-width: 34px; text-align: center;
  padding: 6px 0; font-weight: 700; flex-shrink: 0 }
.bt-chap-name { flex: 1; min-width: 0; font-size: 12.5px }
.bt-chap-cnt { font-size: 11.5px; color: var(--muted, #777); flex-shrink: 0 }

.bt-phans { display: flex; flex-direction: column; gap: 4px; margin-bottom: 4px }
.bt-phan { border: 1px solid var(--border, #d7dce3); border-radius: 8px; overflow: hidden }
.bt-phan-hd { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left;
  background: var(--thead, #f2f5f9); border: 0; padding: 9px 10px; min-height: 44px; cursor: pointer; font-weight: 700 }
.bt-phan-hd:hover { background: #eef3fa }
.bt-phan-no { background: #1a4b8c; color: #fff; border-radius: 6px; padding: 6px 8px;
  font-weight: 700; flex-shrink: 0; font-size: 11.5px; white-space: nowrap }
.bt-phan-name { flex: 1; min-width: 0; font-size: 12.5px }
.bt-phan-cnt { font-size: 11.5px; color: var(--muted, #777); flex-shrink: 0 }
.bt-phan-caret { transition: transform .15s; flex-shrink: 0 }
.bt-phan.open .bt-phan-caret { transform: rotate(180deg) }
.bt-phan-body { display: none; padding: 6px 10px 8px }
.bt-phan.open .bt-phan-body { display: flex; flex-direction: column; gap: 4px }

.bt-crumb { font-size: 12.5px; margin-bottom: 4px; color: var(--muted, #555) }
.bt-tnode { border: 1px solid var(--border, #d7dce3); border-radius: 8px; margin-bottom: 6px; overflow: hidden }
.bt-thead { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left;
  background: var(--thead, #f2f5f9); border: 0; padding: 9px 10px; min-height: 44px; cursor: pointer; font-weight: 700 }
.bt-tnode .bt-tkids { display: none; padding: 4px 6px }
.bt-tnode.open .bt-tkids { display: block }
.bt-tnode.open .bt-tcaret { transform: rotate(180deg) }
.bt-tcaret { margin-left: auto; transition: transform .15s }
.bt-trow { display: flex; gap: 8px; align-items: baseline; padding: 7px 8px; border-radius: 6px;
  font-size: 12.5px; min-height: 34px }
.bt-trow[data-hs], .bt-trow[data-tree] { cursor: pointer }
.bt-trow[data-hs]:hover, .bt-trow[data-tree]:hover { background: #eef3fa }

.bt-ckids { display: none }
.bt-cnode.open > .bt-ckids { display: block }
.bt-crow-p { cursor: pointer }
.bt-crow-p:hover { background: #eef3fa }
.bt-ccaret { margin-left: auto; flex-shrink: 0; transition: transform .15s }
.bt-cnode.open > .bt-crow-p .bt-ccaret { transform: rotate(180deg) }

.bt-clv1 { margin-left: 10px; border-left: 3px solid #052241 }
.bt-clv2 { margin-left: 26px; border-left: 3px solid #0a3760 }
.bt-clv3 { margin-left: 42px; border-left: 3px solid #114a80 }
.bt-clv4 { margin-left: 58px; border-left: 3px solid #1a63a3 }
.bt-clv5 { margin-left: 74px; border-left: 3px solid #2478bf }
.bt-clv6 { margin-left: 90px; border-left: 3px solid #338fd1 }
.bt-hrow { color: #1a4b8c; font-style: italic }
.bt-hrow .bt-tname { font-weight: 600 }
.bt-tma { font-family: monospace; font-weight: 700; color: #1a4b8c; flex-shrink: 0 }
.bt-tname { flex: 1; min-width: 0; word-break: break-word }
.bt-tmeta { flex-shrink: 0; font-size: 11.5px; color: var(--muted, #777) }
.bt-hl { background: #ffe873 !important; outline: 2px solid #e0b400 }

.bt-cap {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; min-width: 18px; border-radius: 3px;
  font-size: 10px; font-weight: 800; color: #fff; flex-shrink: 0; line-height: 1;
}
.bt-cap-1 { background: #052241 }
.bt-cap-2 { background: #0a3760 }
.bt-cap-3 { background: #114a80 }
.bt-cap-4 { background: #1a63a3 }
.bt-cap-5 { background: #2478bf }
.bt-cap-6 { background: #338fd1 }

.bt-bread { font-size: 12px; color: var(--muted, #666); margin-bottom: 8px; word-break: break-word }
.bt-bc { color: #1a4b8c; cursor: pointer; text-decoration: underline }
.bt-card { border: 1px solid var(--border, #d7dce3); border-radius: 10px; padding: 10px 12px; margin-bottom: 10px; background: #fff }
.bt-card-hd { font-weight: 700; margin-bottom: 8px; font-size: 13.5px }
.bt-hs-big { font-size: 17px; font-weight: 800; color: #1a4b8c; margin-bottom: 4px }
.bt-mini { font-size: 11.5px; color: var(--muted, #8a94a3) }
.bt-link { background: none; border: 0; color: #1a4b8c; cursor: pointer; padding: 8px 0; min-height: 44px; font-size: 12.5px }
.bt-link:hover { text-decoration: underline }

.bt-cg-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 6px }
.bt-cg-row .bt-link { justify-self: center; text-align: center; width: 100% }
@media (max-width: 768px) { .bt-cg-row { grid-template-columns: 1fr } }
.bt-taxrow { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0;
  border-bottom: 1px dashed var(--border, #e3e8ef); font-size: 13px }
.bt-taxrow:last-child { border-bottom: 0 }
.bt-taxlbl { color: var(--muted, #555) }
.bt-taxval { font-weight: 700; text-align: right; word-break: break-word }
.bt-taxval small { font-weight: 400; color: var(--muted, #8a94a3); display: block }
.bt-vb { font-weight: 700; display: block; margin-top: 2px; color: inherit;
  white-space: normal; word-break: break-word; overflow-wrap: break-word }
.bt-suat { color: #0b7a3b; font-size: 15px }
.bt-fta-pick { margin-top: 10px; position: relative }
.bt-fta-list { position: absolute; z-index: 30; left: 0; right: 0; background: #fff;
  border: 1px solid var(--border, #d7dce3); border-radius: 8px; max-height: 220px; overflow: auto;
  box-shadow: 0 6px 18px rgba(0,0,0,.12) }
.bt-fta-item { display: block; width: 100%; text-align: left; background: none; border: 0;
  border-bottom: 1px solid var(--border, #eef1f5); padding: 9px 10px; min-height: 44px; cursor: pointer; font-size: 12.5px }
.bt-fta-item:hover { background: #eef3fa }
.bt-fta-card { margin-top: 10px; border: 1px solid #bfd7f0; background: #f4f9ff; border-radius: 8px; padding: 8px 10px }
.bt-fta-name { margin-bottom: 4px; font-size: 13px }
.bt-csrow { padding: 7px 0; font-size: 12.5px; border-bottom: 1px dashed var(--border, #e3e8ef); word-break: break-word }
.bt-csrow:last-child { border-bottom: 0 }
.bt-csrow .fa { color: #b58900 }
.bt-chugiai { white-space: pre-wrap; font-size: 13px; line-height: 1.55; max-height: 60vh; overflow: auto }

.bt-cg { background: none; border: 0; color: #1a4b8c; cursor: pointer; font-size: 11.5px;
  text-decoration: underline; padding: 2px 4px }
.bt-cg:hover { color: #0d3a6f }
.bt-cg-ico { text-decoration: none; padding: 4px 6px; flex-shrink: 0 }
.bt-cg-ico:hover { background: #e3ecf7; border-radius: 4px }

.bt-shotmode { max-height: none !important; overflow: visible !important }
.bt-shot-hd { background: #1a4b8c; color: #fff; font-size: 14px; padding: 10px 12px;
  border-radius: 8px; margin-bottom: 10px }

.bt-shot-disc { font-size: 10.5px; font-style: italic; line-height: 1.4; color: #8a6d1a;
  background: #fffbea; border: 1px solid #f0dfa0; border-radius: 6px; padding: 6px 10px; margin-bottom: 10px }
.bt-shot-ft { border-top: 2px solid #1a4b8c; color: #4a5568; font-size: 11px;
  padding-top: 8px; margin-top: 10px }
.bt-shot-fb p { margin: 0 0 10px }

.bt-postree { margin: 6px 0 8px; border-left: 2px solid var(--border, #d7dce3); padding-left: 4px }
.bt-pt-row { display: flex; gap: 6px; align-items: baseline; padding: 3px 4px; font-size: 12.5px; border-radius: 5px }
.bt-pt-l1 { margin-left: 0 }
.bt-pt-l2 { margin-left: 14px }
.bt-pt-l3 { margin-left: 28px }
.bt-pt-l4 { margin-left: 42px }
.bt-pt-cur { background: #ffe873 }
.bt-pt-txt { display: flex; flex-direction: column; min-width: 0 }
.bt-pt-vn { font-weight: 700; word-break: break-word }
.bt-pt-en { color: var(--muted, #8a94a3); font-style: italic; word-break: break-word }

.bt-cg-html { white-space: normal }
.bt-cg-html p { margin: 0 0 8px }

.bt-cg-html h2, .bt-cg-html h3, .bt-cg-html h4 { margin: 0; line-height: 1.4 }
.bt-cg-html h2.cgt { font-size: 15px; font-weight: 800; color: #1a4b8c; margin: 10px 0 6px }
.bt-cg-html h3.cgh { font-size: 13.5px; font-weight: 800; color: #0d3a6f; margin: 12px 0 4px }
.bt-cg-html h4.cgn { font-size: 12.5px; font-weight: 700; color: #7a5d00; margin: 8px 0 4px }
.bt-cg-html p.lv1 { margin: 4px 0 }
.bt-cg-html p.lv2 { margin: 4px 0 4px 1.5rem }
.bt-cg-html p.lv3 { margin: 4px 0 4px 3rem }
.bt-cg-html p.lv4 { margin: 4px 0 4px 4.5rem }
.bt-cg-html p.lv5 { margin: 4px 0 4px 6rem }
.bt-cg-html p.lv6 { margin: 4px 0 4px 7.5rem }
.bt-cg-html b { color: #143d63 }
.bt-cg-html i { color: #55606e }

.bt-cg-out:empty { display: none }
.bt-cg-box { border: 1px solid #bfd7f0; background: #f7faff; border-radius: 8px; padding: 10px 12px; margin: 8px 0 }
.bt-cg-hd { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; color: #1a4b8c }
.bt-cg-hd-acts { display: flex; gap: 4px; align-items: center; flex-shrink: 0 }
.bt-cg-box .bt-chugiai { max-height: 340px; overflow: auto }

.bt-nd-item { border-left: 3px solid #e0b400; background: #fffdf3; border-radius: 6px;
  padding: 8px 10px; margin-bottom: 8px; font-size: 12.5px; word-break: break-word }
.bt-nd-src { margin-top: 4px; font-size: 11.5px; color: #7a8694 }
.bt-nd-src .bt-link { padding: 4px 0; min-height: 0 }
.bt-nd-more { width: 100%; min-height: 44px }

.bt-ico.on { background: #fff3c4; border-color: #b58900; color: #7a5d00 }
.bt-mark { background: #ffe873; color: inherit; padding: 0; border-radius: 2px }
.bt-hlmode-del .bt-mark { cursor: pointer; outline: 1px dashed #b58900 }


.btm-ov {
  position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 10500;
  display: none; align-items: center; justify-content: center; padding: 20px;
}
.btm-ov.show { display: flex }
.btm-box {
  background: #fff; border-radius: 10px; width: 720px; max-width: 96vw;
  max-height: 90vh; display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.4); position: relative;
}
.btm-hd { display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-bottom: 1px solid var(--border, #d7dce3); background: #f7f9fb; flex-shrink: 0 }
.btm-title { margin: 0; flex: 1; min-width: 0; color: #1a4b8c; font-size: 14.5px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap }
.btm-tools { display: flex; gap: 4px; flex-shrink: 0 }
.btm-x { background: none; border: none; font-size: 24px; line-height: 1; cursor: pointer; color: #99a4b0;
  min-width: 32px; min-height: 32px; flex-shrink: 0 }
.btm-x:hover { color: #c0392b }
.btm-bd { padding: 14px 16px; overflow: auto; position: relative }

.btm-bd .bt-chugiai { font-size: inherit; max-height: none }
.btm-bd .bt-cg-html h2.cgt { font-size: 1.18em }
.btm-bd .bt-cg-html h3.cgh { font-size: 1.08em }
.btm-bd .bt-cg-html h4.cgn { font-size: 1.0em }
.btm-bd .bt-mini { font-size: .88em }


.bt-wm {
  position: absolute; inset: 0; pointer-events: none; z-index: 5;
  opacity: .15;
  background-repeat: repeat;
  background-size: 420px 300px;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='300'%3E%3Ctext x='210' y='160' font-family='Arial, Helvetica, sans-serif' font-size='42' font-weight='700' fill='%23888888' text-anchor='middle' transform='rotate(-30 210 150)'%3Eweimex.vn%3C/text%3E%3C/svg%3E");
}


.bt-toolbtn { min-height: 44px }
.bt-vatpl-table { width: 100%; border-collapse: collapse; font-size: inherit }
.bt-vatpl-table th, .bt-vatpl-table td { border: 1px solid var(--border, #d7dce3); padding: 6px 8px; text-align: left; vertical-align: top; word-break: break-word; overflow-wrap: break-word }
.bt-vatpl-table th { background: #eef3fa; color: #1a4b8c; position: sticky; top: 0 }
.bt-vatpl-table .vp-hs { white-space: nowrap; font-family: monospace; color: #0d3a6f }
.bt-quytac .qt-tieude { font-size: 1.15em; font-weight: 800; color: #1a4b8c; text-align: center; margin: 8px 0 }
.bt-quytac .qt-quytac { font-size: 1.08em; font-weight: 800; color: #0d3a6f; margin-top: 14px }
.bt-quytac .qt-chugiai { font-size: 1.02em; font-weight: 700; color: #7a5d00; margin-top: 10px }
.bt-vatpl2 p { margin: 4px 0 }

@media (max-width: 768px) {
  .bt-wrap { flex-direction: column }
  .bt-panel-bd { max-height: none }
  
  .bt-ico { min-width: 44px; min-height: 44px }
  .bt-chip { min-height: 44px }
  .bt-bc { padding: 6px 2px; display: inline-block }
  .bt-cg-ico { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center }
  .bt-cg { min-height: 44px; display: inline-flex; align-items: center }
  .btm-x { min-width: 44px; min-height: 44px }
  .bt-nd-open { min-height: 44px; display: inline-flex; align-items: center }
  .bt-crow-p { min-height: 44px }
  
  .bt-clv1 { margin-left: 6px }
  .bt-clv2 { margin-left: 14px }
  .bt-clv3 { margin-left: 22px }
  .bt-clv4 { margin-left: 30px }
  .bt-clv5 { margin-left: 38px }
  .bt-clv6 { margin-left: 46px }
}
