/* tickmi.com/tao-ma-qr-hang-loat — công cụ tạo mã QR hàng loạt. Dùng token của styles.css (--brand, --line, --shadow…). */
.qb-hero { position: relative; padding: 28px 0 56px; background: linear-gradient(180deg, var(--soft), #fff 70%); }
.qb-glow { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.qb-glow:before, .qb-glow:after { content: ""; position: absolute; border-radius: 50%; filter: blur(70px); opacity: .45; }
.qb-glow:before { width: 420px; height: 420px; background: var(--brand-3); top: -160px; right: -80px; }
.qb-glow:after { width: 320px; height: 320px; background: #ffe2d6; bottom: -120px; left: -100px; }
.qb-hero .wrap { position: relative; }
.qb-hero h1 { font-size: clamp(30px, 4vw, 48px); margin: 14px 0 10px; }
.qb-hero h1 em { font-style: normal; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.qb-lead { color: var(--muted); max-width: 720px; margin: 0 0 24px; font-size: 17px; }

.qb-tool { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.qb-panel, .qb-preview { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.qb-panel { padding: 8px 22px; }
.qb-step { padding: 16px 0; border-bottom: 1px solid var(--line); }
.qb-step:last-child { border-bottom: 0; }
.qb-step h2 { font-size: 17px; display: flex; align-items: center; gap: 10px; margin: 0 0 8px; }
.qb-step h2 span { width: 26px; height: 26px; border-radius: 50%; background: var(--grad); color: #fff; font-size: 13px; display: grid; place-items: center; flex: none; }
.qb-hint { color: var(--muted); font-size: 14px; margin: 0 0 10px; }
.qb-panel textarea { width: 100%; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; font: 14px/1.55 ui-monospace, SFMono-Regular, Consolas, monospace; resize: vertical; min-height: 180px; background: #fcfcfd; }
.qb-panel textarea:focus, .qb-panel select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(255,92,64,.18); }
.qb-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; margin: 8px 0 4px; font-size: 14px; }
.qb-count { font-weight: 700; }
.qb-count.is-warn { color: #b45309; }
.qb-link { background: none; border: 0; padding: 0; color: var(--brand-dark); font: inherit; font-weight: 600; cursor: pointer; }
.qb-link:hover { text-decoration: underline; }
.qb-danger { color: #b91c1c; }
.qb-file { position: relative; overflow: hidden; }
.qb-file input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.qb-check { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; margin-top: 8px; cursor: pointer; }
.qb-check input { margin-top: 4px; accent-color: var(--brand); }
.qb-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.qb-field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.qb-field select { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; font: inherit; font-weight: 500; background: #fff; }
.qb-colors { display: flex; gap: 10px; }
.qb-colors label { display: flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 12px; padding: 5px 10px 5px 5px; font-weight: 500; cursor: pointer; }
.qb-colors input { width: 30px; height: 30px; border: 0; padding: 0; background: none; cursor: pointer; }
.qb-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.qb-actions .btn[disabled] { opacity: .45; pointer-events: none; }
.qb-progress { display: flex; align-items: center; gap: 10px; margin-top: 12px; font-size: 13px; color: var(--muted); }
.qb-bar { flex: 1; height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; }
.qb-bar i { display: block; height: 100%; width: 0; background: var(--grad); transition: width .15s; }
.qb-msg { margin: 10px 0 0; font-size: 14px; min-height: 1.4em; }
.qb-msg.is-ok { color: #047857; }
.qb-msg.is-warn { color: #b45309; }
.qb-msg.is-err { color: #b91c1c; }

.qb-preview { padding: 18px; position: sticky; top: 84px; }
.qb-preview-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; }
.qb-preview-note { color: var(--muted); font-size: 13px; }
.qb-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; min-height: 200px; max-height: 470px; overflow: auto; }
.qb-thumb { margin: 0; border: 1px solid var(--line); border-radius: 12px; padding: 6px; background: #fff; display: grid; place-items: center; font-size: 12px; color: #b91c1c; text-align: center; }
.qb-thumb canvas { width: 100%; height: auto; display: block; }
.qb-empty { grid-column: 1 / -1; display: grid; place-items: center; text-align: center; color: var(--muted); border: 1.5px dashed var(--line); border-radius: 14px; padding: 40px 16px; font-size: 14px; }
.qb-upsell { display: block; margin-top: 16px; padding: 14px 16px; border-radius: 16px; background: var(--soft); text-decoration: none; border: 1px solid #ffe0d6; }
.qb-upsell b { display: block; margin-bottom: 4px; }
.qb-upsell span { display: block; font-size: 14px; color: var(--ink-2); }
.qb-upsell em { display: inline-block; margin-top: 8px; font-style: normal; font-weight: 700; color: var(--brand-dark); }

.qb-seo .qb-h2 { margin-top: 36px; }
.qb-steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.qb-steps li { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; background: #fff; }
.qb-steps li > span { width: 32px; height: 32px; border-radius: 50%; background: var(--grad); color: #fff; display: grid; place-items: center; font-weight: 700; margin-bottom: 10px; }
.qb-steps h3 { font-size: 17px; }
.qb-steps p, .qb-uses p { color: var(--muted); margin: 0; font-size: 15px; }
.qb-uses { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.qb-uses h3 { font-size: 16px; margin-top: 10px; }
.qb-feats { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 24px; }
.qb-feats li { display: flex; gap: 10px; align-items: flex-start; }
.qb-feats svg { width: 20px; height: 20px; color: var(--brand); flex: none; margin-top: 3px; }
.qb-studio { background: var(--soft); border-radius: 28px; padding: 32px; }
.qb-table { overflow-x: auto; margin: 16px 0 22px; }
.qb-table table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 16px; overflow: hidden; font-size: 15px; }
.qb-table th, .qb-table td { padding: 12px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.qb-table thead th { background: #fff8f5; font-size: 14px; }
.qb-related { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; }
.qb-related a { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--brand-dark); text-decoration: none; }
.qb-related svg { width: 16px; height: 16px; }

@media (max-width: 900px) {
  .qb-tool { grid-template-columns: 1fr; }
  .qb-preview { position: static; }
  .qb-steps, .qb-uses { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .qb-panel { padding: 4px 16px; }
  .qb-grid, .qb-steps, .qb-uses, .qb-feats, .qb-related { grid-template-columns: 1fr; }
  .qb-actions .btn { flex: 1 1 100%; justify-content: center; }
  .qb-studio { padding: 22px 16px; }
  .qb-table thead { display: none; }
  .qb-table tr { display: block; border-bottom: 1px solid var(--line); }
  .qb-table th, .qb-table td { display: block; border: 0; padding: 6px 14px; }
  .qb-table td:before { content: attr(data-label) ": "; font-weight: 600; color: var(--ink-2); }
}
@media (prefers-reduced-motion: reduce) { .qb-bar i { transition: none; } }
