/* qrcode.27biggroup.com — giao diện chung. Màu khai báo bằng biến ở :root; chế độ tối đổi biến, không đổi luật. */

:root {
  --bg: #f6f7fb;
  --surface: #ffffff;
  --surface-2: #f1f3f9;
  --line: #e3e6ef;
  --ink: #141729;
  --ink-2: #4a5068;
  --ink-3: #7a8098;
  --brand: #4f46e5;
  --brand-2: #7c3aed;
  --brand-ink: #ffffff;
  --brand-soft: #eef0ff;
  --gold: #f59e0b;
  --gold-ink: #3b2400;
  --ok: #059669;
  --danger: #dc2626;
  --warn-bg: #fff7e6;
  --warn-ink: #8a5300;
  --shadow: 0 1px 2px rgba(20, 23, 41, .05), 0 6px 24px rgba(20, 23, 41, .06);
  --radius: 16px;
  --font: 'Be Vietnam Pro', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d0f1a;
    --surface: #161a2b;
    --surface-2: #1d2236;
    --line: #2a3048;
    --ink: #eef0fa;
    --ink-2: #b5bad0;
    --ink-3: #8a90a8;
    --brand: #7c78ff;
    --brand-2: #a78bfa;
    --brand-ink: #0d0f1a;
    --brand-soft: #23264a;
    --warn-bg: #3a2a0c;
    --warn-ink: #ffd58a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 28px rgba(0, 0, 0, .35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0d0f1a; --surface: #161a2b; --surface-2: #1d2236; --line: #2a3048; --ink: #eef0fa; --ink-2: #b5bad0; --ink-3: #8a90a8;
  --brand: #7c78ff; --brand-2: #a78bfa; --brand-ink: #0d0f1a; --brand-soft: #23264a; --warn-bg: #3a2a0c; --warn-ink: #ffd58a;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; text-wrap: balance; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }
.center { text-align: center; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.ic { flex: none; vertical-align: middle; }
.page-title { font-size: clamp(26px, 4vw, 34px); font-weight: 800; letter-spacing: -.02em; }
.sec-title { font-size: clamp(22px, 3vw, 28px); font-weight: 800; letter-spacing: -.015em; }
.kicker { display: inline-flex; gap: 6px; align-items: center; font-weight: 700; font-size: 13px; color: var(--brand); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 8px; }

/* ── Nút ─────────────────────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 18px; border-radius: 12px;
  border: 1px solid transparent; font-weight: 700; font-size: 15px; cursor: pointer; text-decoration: none !important; white-space: nowrap;
  transition: transform .12s, box-shadow .15s, background .15s; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn--sm { min-height: 36px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
.btn--lg { min-height: 54px; padding: 0 26px; font-size: 17px; }
.btn--primary { background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; box-shadow: 0 6px 18px rgba(79, 70, 229, .3); }
.btn--primary:hover { box-shadow: 0 8px 24px rgba(79, 70, 229, .4); }
.btn--soft { background: var(--brand-soft); color: var(--brand); }
.btn--ghost { background: var(--surface); color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--ink-3); }
.btn--dark { background: var(--ink); color: var(--bg); }
.btn--gold { background: linear-gradient(135deg, #fbbf24, #f59e0b); color: var(--gold-ink); box-shadow: 0 6px 18px rgba(245, 158, 11, .3); }
.btn--danger { background: var(--danger); color: #fff; }
.btn.is-static { cursor: default; opacity: .8; }

.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink-2); cursor: pointer; }
.icon-btn:hover { color: var(--brand); border-color: var(--brand); text-decoration: none; }
.icon-btn--danger:hover { color: var(--danger); border-color: var(--danger); }

.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink-2); font-weight: 600; font-size: 14px; cursor: pointer; }
.chip.is-active { background: var(--ink); border-color: var(--ink); color: var(--bg); }

.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; border-radius: 999px; background: var(--surface-2); font-weight: 700; font-size: 13px; }
.badge--pro, .tpl__pro, .pro-tag { background: linear-gradient(135deg, #fde68a, #f59e0b); color: var(--gold-ink); }
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 6px; background: var(--surface-2); color: var(--ink-2); font-size: 12px; font-weight: 600; }
.tag--dyn { background: #e7f8f0; color: #04694b; }
.tag--paused { background: #fdecec; color: #a11b1b; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tag--dyn { background: #0f3327; color: #7fe0b8; } :root:not([data-theme="light"]) .tag--paused { background: #3d1515; color: #ffb4b4; } }

.card, .panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }

.note { margin: 12px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--brand-soft); color: var(--ink-2); font-size: 13px; line-height: 1.5; word-break: break-word; }
.note--warn { background: var(--warn-bg); color: var(--warn-ink); }

/* ── Đầu trang ───────────────────────────────────────────────────────────── */
.site-head { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line); }
.site-head__in { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none !important; font-weight: 800; font-size: 19px; letter-spacing: -.02em; }
.brand__mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; }
.brand__word b { color: var(--brand); }
.site-nav { display: flex; gap: 4px; margin-right: auto; }
.site-nav a { padding: 8px 12px; border-radius: 10px; color: var(--ink-2); font-weight: 600; text-decoration: none; }
.site-nav a:hover { background: var(--surface-2); color: var(--ink); }
.site-nav a.is-active { color: var(--brand); background: var(--brand-soft); }
.site-head__acc { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.nav-toggle { display: none; width: 42px; height: 42px; border: 0; border-radius: 10px; background: transparent; cursor: pointer; }
.acc-menu { position: relative; }
.acc-menu summary { list-style: none; cursor: pointer; border-radius: 50%; }
.acc-menu summary::-webkit-details-marker { display: none; }
.acc-menu img, .acc-menu__ini { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: var(--brand); color: #fff; font-weight: 800; }
.acc-menu__pop { position: absolute; right: 0; top: calc(100% + 8px); min-width: 230px; padding: 8px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 14px; box-shadow: var(--shadow); }
.acc-menu__pop a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: var(--ink); text-decoration: none; font-weight: 500; }
.acc-menu__pop a:hover { background: var(--surface-2); }
.acc-menu__name { margin: 4px 10px 8px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 760px) {
  .site-head__in { gap: 12px; }
  .nav-toggle { display: grid; place-items: center; color: var(--ink); }
  .site-nav { position: absolute; left: 0; right: 0; top: 64px; flex-direction: column; padding: 8px 16px 16px; background: var(--surface);
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow); display: none; }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 12px; }
}

/* ── Quảng cáo ───────────────────────────────────────────────────────────── */
.ad { position: relative; margin: 24px auto; min-height: 100px; text-align: center; }
.ad__label { display: block; font-size: 11px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 4px; }
.ad--placeholder { display: grid; place-items: center; min-height: 110px; border: 2px dashed var(--line); border-radius: 12px; color: var(--ink-3); font-size: 13px; }

/* ── Mở đầu ──────────────────────────────────────────────────────────────── */
.hero { padding: 40px 0 8px; text-align: center;
  background: radial-gradient(60% 120% at 50% 0%, color-mix(in srgb, var(--brand) 12%, transparent), transparent 70%); }
.hero__title { font-size: clamp(30px, 5.4vw, 50px); font-weight: 800; letter-spacing: -.03em; margin-bottom: 12px;
  background: linear-gradient(135deg, var(--ink) 30%, var(--brand) 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__lead { max-width: 680px; margin: 0 auto 16px; font-size: 17px; color: var(--ink-2); }
.hero__chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; padding: 0; margin: 0; list-style: none; color: var(--ink-2); font-weight: 600; font-size: 14px; }
.hero__chips li { display: inline-flex; align-items: center; gap: 6px; }
.hero__chips .ic { color: var(--ok); }

/* ── Công cụ tạo QR ──────────────────────────────────────────────────────── */
.maker { display: grid; grid-template-columns: minmax(0, 1fr) 380px; grid-template-areas: "content preview" "design preview"; gap: 20px; align-items: start; margin: 20px auto 40px; }
.maker__content { grid-area: content; }
.maker__design { grid-area: design; }
.maker__preview { grid-area: preview; position: sticky; top: 80px; }
.panel { padding: 20px; min-width: 0; }
.step { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 800; margin-bottom: 16px; }
.step__no { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 14px; flex: none; }

@media (max-width: 959px) {
  .maker { grid-template-columns: minmax(0, 1fr); grid-template-areas: "content" "preview" "design"; }
  .maker__preview { position: static; }
}

.type-tabs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin-bottom: 18px; }
.type-tab { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink-2); font-weight: 600; font-size: 13px; cursor: pointer; text-align: center; line-height: 1.25; transition: border-color .15s, background .15s; }
.type-tab:hover:not(:disabled) { border-color: var(--brand); color: var(--ink); }
.type-tab.is-active { border-color: var(--brand); background: var(--brand-soft); color: var(--brand); box-shadow: inset 0 0 0 1px var(--brand); }
.type-tab:disabled:not(.is-active) { opacity: .45; cursor: not-allowed; }
@media (max-width: 560px) {
  .type-tabs { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -20px 18px; padding: 2px 20px 6px; scrollbar-width: none; }
  .type-tabs::-webkit-scrollbar { display: none; }
  .type-tab { flex: 0 0 84px; scroll-snap-align: start; }
}

.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.fld { display: flex; flex-direction: column; gap: 6px; min-width: 0; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.fld--wide { grid-column: 1 / -1; }
.fld input:not([type="checkbox"]):not([type="color"]):not([type="range"]), .fld select, .fld textarea, .save input {
  width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); font-weight: 500; font-size: 15px; }
.fld textarea { resize: vertical; min-height: 100px; line-height: 1.5; }
.fld input:focus, .fld select:focus, .fld textarea:focus, .save input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 20%, transparent); }
.fld input:disabled { opacity: .5; }
.fld__hint { font-weight: 400; color: var(--ink-3); font-size: 12.5px; }
.req { color: var(--danger); font-style: normal; }
@media (max-width: 560px) { .fields { grid-template-columns: minmax(0, 1fr); } }

.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; font-size: 15px; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch__track { position: relative; flex: none; width: 46px; height: 26px; border-radius: 999px; background: var(--line); transition: background .15s; }
.switch__track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .15s; }
.switch input:checked + .switch__track { background: var(--brand); }
.switch input:checked + .switch__track::after { transform: translateX(20px); }
.switch input:focus-visible + .switch__track { outline: 2px solid var(--brand); outline-offset: 2px; }
.switch input:disabled + .switch__track { opacity: .5; }
.switch--sm { font-size: 14px; color: var(--ink-2); font-weight: 600; margin: 4px 0 14px; }
.switch.is-disabled { opacity: .5; pointer-events: none; }

.dyn { margin-top: 18px; padding: 14px; border-radius: 12px; background: var(--surface-2); }
.dyn__help { margin: 8px 0 0; font-size: 13px; color: var(--ink-2); word-break: break-word; }
.dyn.is-off .switch { opacity: .55; }

/* Xem trước */
.preview { position: relative; display: grid; place-items: center; padding: 18px; border-radius: 14px; min-height: 280px;
  background: repeating-conic-gradient(var(--surface-2) 0% 25%, var(--surface) 0% 50%) 50% / 20px 20px; }
.preview__box { width: 100%; display: grid; place-items: center; }
.preview__box svg { width: 100%; height: auto; max-height: 440px; filter: drop-shadow(0 8px 20px rgba(20, 23, 41, .12)); }
.preview__box.is-empty svg { opacity: .2; filter: grayscale(1) blur(1px); }
.preview__err { color: var(--danger); text-align: center; font-weight: 600; }
.preview__pro { position: absolute; top: 10px; right: 10px; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px;
  background: linear-gradient(135deg, #fde68a, #f59e0b); color: var(--gold-ink); font-weight: 800; font-size: 12px; }

.dl { display: grid; grid-template-columns: 1fr auto; gap: 10px; margin-top: 16px; }
.dl__size { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.dl__size select { min-height: 38px; padding: 0 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.save { display: grid; gap: 10px; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
.save__hint { font-size: 13px; margin: 10px 0 0; }

/* Thiết kế */
.dtabs { display: flex; gap: 4px; padding: 4px; margin-bottom: 16px; border-radius: 12px; background: var(--surface-2); overflow-x: auto; scrollbar-width: none; }
.dtabs::-webkit-scrollbar { display: none; }
.dtab { flex: 1 0 auto; min-height: 38px; padding: 0 14px; border: 0; border-radius: 9px; background: transparent; color: var(--ink-2); font-weight: 700; font-size: 14px; cursor: pointer; white-space: nowrap; }
.dtab.is-active { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(20, 23, 41, .1); }
.tpl-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.tpl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(116px, 1fr)); gap: 12px; }
.tpl { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
  cursor: pointer; text-align: center; transition: border-color .15s, transform .15s; }
.tpl:hover { border-color: var(--brand); transform: translateY(-2px); }
.tpl.is-active { border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand); }
.tpl__img { display: grid; place-items: center; aspect-ratio: 1; border-radius: 8px; background: var(--surface-2); padding: 6px; overflow: hidden; }
.tpl__img svg { width: 100%; height: 100%; object-fit: contain; }
.tpl__name { font-size: 12.5px; font-weight: 600; color: var(--ink-2); line-height: 1.3; }
.tpl__pro { position: absolute; top: 4px; right: 4px; padding: 1px 7px; border-radius: 999px; font-size: 10.5px; font-weight: 800; letter-spacing: .04em; }
.pro-tag { display: inline-flex; align-items: center; gap: 3px; padding: 0 6px; border-radius: 999px; font-style: normal; font-size: 11px; font-weight: 800; vertical-align: 1px; }

.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
@media (max-width: 480px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }
.color { display: flex; gap: 8px; }
.color input[type="color"] { flex: none; width: 46px; height: 46px; padding: 3px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); cursor: pointer; }
.color input[type="text"] { font-family: ui-monospace, Menlo, Consolas, monospace; text-transform: lowercase; }
.pane-label { margin: 6px 0 8px; font-weight: 700; font-size: 14px; color: var(--ink-2); }
.opt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; margin-bottom: 14px; }
.opt-grid--frame { grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); }
.opt { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 6px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--surface); cursor: pointer; }
.opt:hover { border-color: var(--brand); }
.opt.is-active { border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand); }
.opt__img { display: grid; place-items: center; width: 54px; height: 54px; }
.opt-grid--frame .opt__img { width: 70px; height: 70px; }
.opt__img svg { width: 100%; height: 100%; }
.opt__name { font-size: 12px; font-weight: 600; color: var(--ink-2); text-align: center; line-height: 1.25; }

.logo-drop { display: flex; gap: 16px; align-items: center; padding: 16px; border: 2px dashed var(--line); border-radius: 14px; margin-bottom: 14px; }
.logo-drop__img { flex: none; display: grid; place-items: center; width: 84px; height: 84px; border-radius: 12px; background: repeating-conic-gradient(var(--surface-2) 0% 25%, var(--surface) 0% 50%) 50% / 12px 12px; }
.logo-drop__img img { max-width: 72px; max-height: 72px; }
.logo-drop__txt p { margin: 0 0 6px; font-size: 14px; }
.logo-drop__btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.fld--range input { width: 100%; accent-color: var(--brand); }

.mini-preview { position: fixed; right: 16px; bottom: 16px; z-index: 30; width: 92px; padding: 6px; border: 0; border-radius: 14px; background: var(--surface);
  box-shadow: 0 10px 30px rgba(20, 23, 41, .25); cursor: pointer; }
.mini-preview svg { display: block; width: 100%; height: auto; }

/* ── Phần nội dung trang chủ ─────────────────────────────────────────────── */
.guide, .kinds, .faq, .teaser { margin: 56px auto; }
.guide__steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; padding: 0; margin: 20px 0 0; list-style: none; }
.guide__steps li { padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.guide__steps h3 { font-size: 17px; margin: 12px 0 6px; }
.guide__steps p { color: var(--ink-2); margin: 0; font-size: 14.5px; }
.guide__no { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--brand-soft); color: var(--brand); font-weight: 800; font-size: 18px; }
@media (max-width: 760px) { .guide__steps { grid-template-columns: minmax(0, 1fr); } }

.kinds__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 20px; }
.kind { display: flex; gap: 14px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; color: var(--ink); text-decoration: none !important;
  transition: border-color .15s, transform .15s; }
.kind:hover { border-color: var(--brand); transform: translateY(-2px); }
.kind__ic { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--brand-soft); color: var(--brand); }
.kind__body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kind__body span { color: var(--ink-2); font-size: 13.5px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.teaser__in { display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: center; padding: 32px; border-radius: 24px; color: #fff;
  background: linear-gradient(135deg, #312e81, #4f46e5 55%, #7c3aed); box-shadow: var(--shadow); }
.teaser .kicker { color: #c7d2fe; }
.teaser .sec-title { color: #fff; }
.teaser p { color: #e0e7ff; }
.teaser__btns { display: flex; flex-wrap: wrap; gap: 10px; }
.teaser .btn--primary { background: #fff; color: #312e81; box-shadow: none; }
.teaser .btn--ghost { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.teaser__chart { display: flex; align-items: flex-end; gap: 6px; height: 180px; padding: 16px; border-radius: 16px; background: rgba(255, 255, 255, .1); }
.teaser__chart span { flex: 1; border-radius: 4px 4px 0 0; background: linear-gradient(to top, #a5b4fc, #fff); }
@media (max-width: 760px) { .teaser__in { grid-template-columns: minmax(0, 1fr); padding: 24px; } .teaser__chart { height: 120px; } }

.faq__item { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; margin-bottom: 10px; }
.faq__item summary { cursor: pointer; padding: 16px 18px; font-weight: 700; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after { content: '+'; font-size: 20px; line-height: 1; color: var(--brand); }
.faq__item[open] summary::after { content: '–'; }
.faq__item p { padding: 0 18px 16px; margin: 0; color: var(--ink-2); }

/* ── Hộp thoại + thông báo ───────────────────────────────────────────────── */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; background: rgba(13, 15, 26, .55); backdrop-filter: blur(3px); }
.modal__card { position: relative; width: 100%; max-width: 420px; padding: 28px 24px 22px; border-radius: 20px; background: var(--surface); box-shadow: 0 30px 80px rgba(0, 0, 0, .35); text-align: center; }
.modal__card h3 { font-size: 20px; }
.modal__card p { color: var(--ink-2); }
.modal__ic { display: inline-grid; place-items: center; width: 56px; height: 56px; margin-bottom: 12px; border-radius: 16px; background: linear-gradient(135deg, #fde68a, #f59e0b); color: var(--gold-ink); }
.modal__x { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border: 0; border-radius: 10px; background: transparent; color: var(--ink-3); cursor: pointer; }
.modal__btns { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 8px; }
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 110; transform: translateX(-50%); max-width: calc(100% - 32px); padding: 12px 18px; border-radius: 12px;
  background: var(--ink); color: var(--bg); font-weight: 600; box-shadow: 0 12px 30px rgba(0, 0, 0, .25); }
.toast--ok { background: var(--ok); color: #fff; }
.toast--err { background: var(--danger); color: #fff; }

/* ── QR của tôi ──────────────────────────────────────────────────────────── */
.mine { padding-top: 28px; padding-bottom: 48px; }
.mine__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 18px; }
.mine__head .page-title { margin-bottom: 4px; }
.mine__head p { margin: 0; }
.plan-box { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; padding: 16px 18px; margin-bottom: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.plan-box--pro { border-color: #f5c451; background: linear-gradient(135deg, color-mix(in srgb, #fde68a 18%, var(--surface)), var(--surface)); }
.plan-box__name { font-weight: 700; display: flex; align-items: center; gap: 8px; }
.plan-box__meter { display: flex; flex-direction: column; gap: 6px; min-width: 160px; font-size: 14px; color: var(--ink-2); }
.meter { display: block; height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--brand); }
.plan-box .btn { margin-left: auto; }
.mine__filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.qr-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.qr-item { display: grid; grid-template-columns: 96px minmax(0, 1fr) 130px auto; gap: 18px; align-items: center; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.qr-item.is-paused .qr-item__img { opacity: .4; }
.qr-item__img { display: grid; place-items: center; width: 96px; height: 96px; border-radius: 10px; background: var(--surface-2); padding: 4px; }
.qr-item__img svg { width: 100%; height: 100%; }
.qr-item__name { font-size: 16px; margin: 0 0 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qr-item__meta { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 6px; }
.qr-item__sum, .qr-item__short { margin: 0; font-size: 13.5px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qr-item__stats { display: flex; flex-direction: column; text-align: right; line-height: 1.3; }
.qr-item__stats b { font-size: 24px; font-weight: 800; font-variant-numeric: tabular-nums; }
.qr-item__stats span { color: var(--ink-2); font-size: 13px; }
.qr-item__stats small { color: var(--ink-3); font-size: 12px; margin-top: 2px; }
.qr-item__acts { display: flex; gap: 6px; }
@media (max-width: 860px) {
  .qr-item { grid-template-columns: 80px minmax(0, 1fr); gap: 12px 14px; }
  .qr-item__img { width: 80px; height: 80px; }
  .qr-item__stats { grid-column: 1 / 2; text-align: center; }
  .qr-item__stats b { font-size: 20px; }
  .qr-item__acts { grid-column: 2 / 3; justify-content: flex-end; flex-wrap: wrap; }
}
.empty { text-align: center; padding: 56px 16px; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty__ic { display: inline-grid; place-items: center; width: 72px; height: 72px; border-radius: 20px; background: var(--brand-soft); color: var(--brand); margin-bottom: 12px; }

/* ── Thống kê ────────────────────────────────────────────────────────────── */
.stats { padding-top: 22px; padding-bottom: 48px; }
.back { display: inline-block; margin-bottom: 14px; font-weight: 600; }
.stats__head { display: flex; gap: 20px; align-items: center; margin-bottom: 20px; }
.stats__qr { flex: none; width: 120px; padding: 6px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.stats__qr svg { display: block; width: 100%; height: auto; }
.stats__head .page-title { font-size: clamp(22px, 3vw, 28px); margin-bottom: 4px; }
.stats__head p { margin: 0 0 6px; word-break: break-word; }
.stats__btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
@media (max-width: 560px) { .stats__head { flex-direction: column; align-items: flex-start; } }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.tile { padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.tile__label { display: block; color: var(--ink-2); font-size: 13px; font-weight: 600; }
.tile__num { display: block; font-size: 30px; font-weight: 800; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
@media (max-width: 700px) { .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.chart-card { padding: 18px 20px; margin-bottom: 16px; }
.chart-card__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.chart-card__head h2 { font-size: 17px; margin: 0; }
.chart-card__head h2 .muted { font-weight: 500; font-size: 14px; }
.seg { display: inline-flex; padding: 3px; border-radius: 10px; background: var(--surface-2); }
.seg__btn { padding: 6px 12px; border-radius: 8px; color: var(--ink-2); font-weight: 600; font-size: 13px; text-decoration: none !important; white-space: nowrap; }
.seg__btn.is-active { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(20, 23, 41, .1); }
.seg__btn.is-locked { color: var(--ink-3); display: inline-flex; align-items: center; gap: 3px; }
.bars { position: relative; padding-top: 18px; }
.bars__max { position: absolute; top: 0; left: 0; font-size: 12px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.bars__plot { display: flex; align-items: stretch; height: 200px; border-bottom: 1px solid var(--line);
  background: linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 100% 50%; }
.bar { position: relative; flex: 1; min-width: 0; cursor: default; outline: none; }
.bar::before { content: ''; position: absolute; left: 50%; bottom: 0; width: min(70%, 18px); height: var(--h); min-height: 0; transform: translateX(-50%);
  border-radius: 4px 4px 0 0; background: var(--brand); }
.bars__plot--dense .bar::before { width: 80%; border-radius: 1px 1px 0 0; }
.bar.is-hover::before, .bar:focus-visible::before { background: var(--brand-2); }
.bars__axis { display: flex; justify-content: space-between; margin-top: 6px; font-size: 12px; color: var(--ink-3); }
.bars__tip { position: absolute; top: -6px; transform: translateX(-50%); padding: 6px 10px; border-radius: 8px; background: var(--ink); color: var(--bg); font-size: 12.5px;
  font-weight: 600; white-space: nowrap; pointer-events: none; }
.table-view { margin-top: 14px; font-size: 14px; }
.table-view summary { cursor: pointer; color: var(--brand); font-weight: 600; }
.table-view table { width: 100%; border-collapse: collapse; margin-top: 10px; }
.table-view th, .table-view td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; font-variant-numeric: tabular-nums; }
.bd-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 760px) { .bd-grid { grid-template-columns: minmax(0, 1fr); } }
.bd { padding: 18px 20px; }
.bd--wide { grid-column: 1 / -1; }
.bd h2 { font-size: 16px; margin-bottom: 12px; }
.bd__row { display: grid; grid-template-columns: 120px minmax(0, 1fr) 80px; gap: 10px; align-items: center; margin-bottom: 10px; font-size: 14px; }
.bd__k { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); font-weight: 600; }
.bd__bar { height: 10px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.bd__bar span { display: block; height: 100%; border-radius: inherit; background: var(--brand); }
.bd__v { text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; }
.bd__v small { color: var(--ink-3); font-weight: 500; }
.hours { display: grid; grid-template-columns: repeat(24, minmax(0, 1fr)); gap: 3px; }
.hours__cell { position: relative; aspect-ratio: 1 / 1.6; border-radius: 4px; background: color-mix(in srgb, var(--brand) calc(var(--a) * 100%), var(--surface-2)); }
.hours__cell i { position: absolute; bottom: -18px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: 10px; color: var(--ink-3); }
.hours__cell:nth-child(odd) i { visibility: hidden; }
.bd--wide .hours { margin-bottom: 18px; }
.locked { grid-column: 1 / -1; position: relative; overflow: hidden; padding: 24px; min-height: 300px; }
.locked__ghost { filter: blur(5px); opacity: .5; pointer-events: none; }
.locked__msg { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 16px;
  background: color-mix(in srgb, var(--surface) 55%, transparent); }
.locked__msg h2 { font-size: 19px; margin: 10px 0 6px; }
.locked__msg p { max-width: 460px; color: var(--ink-2); font-size: 14px; }

/* ── Mẫu QR ──────────────────────────────────────────────────────────────── */
.gallery { padding-top: 28px; padding-bottom: 48px; }
.gallery__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; margin-top: 8px; }
@media (max-width: 480px) { .gallery__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } .gcard__img { padding: 10px; } .gcard__foot { padding: 8px 10px; font-size: 13px; } }
.gcard { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; color: var(--ink);
  text-decoration: none !important; transition: transform .15s, box-shadow .15s; }
.gcard:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.gcard__img { display: grid; place-items: center; aspect-ratio: 1; padding: 18px; background: var(--surface-2); }
.gcard__img svg { width: 100%; height: 100%; }
.gcard__foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 14px; }
.gcard .tpl__pro { position: static; }

/* ── Bảng giá ────────────────────────────────────────────────────────────── */
.pricing { padding-top: 32px; padding-bottom: 56px; }
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; max-width: 820px; margin: 28px auto; }
.plan { position: relative; padding: 26px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; display: flex; flex-direction: column; gap: 6px; }
.plan h2 { font-size: 20px; margin: 0; }
.plan--pro { border: 2px solid #f5b931; box-shadow: 0 12px 40px rgba(245, 158, 11, .18); }
.plan__ribbon { position: absolute; top: -13px; right: 20px; display: inline-flex; align-items: center; gap: 4px; padding: 3px 12px; border-radius: 999px;
  background: linear-gradient(135deg, #fde68a, #f59e0b); color: var(--gold-ink); font-weight: 800; font-size: 12px; }
.plan__price { margin: 6px 0 0; }
.plan__price b { font-size: 36px; font-weight: 800; letter-spacing: -.02em; }
.plan__price span { color: var(--ink-2); }
.plan .btn { margin-top: auto; }
@media (max-width: 640px) { .plans { grid-template-columns: minmax(0, 1fr); } }
.compare-wrap { max-width: 820px; margin: 0 auto; overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
.compare { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.compare th, .compare td { padding: 12px 16px; border-bottom: 1px solid var(--line); text-align: center; }
.compare th[scope="row"], .compare thead th:first-child { text-align: left; font-weight: 500; }
.compare thead th { background: var(--surface-2); font-weight: 800; }
.compare tbody tr:last-child > * { border-bottom: 0; }
.yes { color: var(--ok); }
.no { color: var(--ink-3); }

/* ── Chính sách ──────────────────────────────────────────────────────────── */
.legal { max-width: 760px; padding-top: 32px; padding-bottom: 56px; }
.legal h2 { font-size: 18px; margin-top: 28px; }
.legal p { color: var(--ink-2); }

/* ── Trang đích QR động ──────────────────────────────────────────────────── */
.landing { min-height: 70vh; display: flex; flex-direction: column; align-items: center; padding: 40px 16px; }
.landing__card { width: 100%; max-width: 440px; padding: 30px 24px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 24px;
  box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center; gap: 12px; }
.landing__card h1 { font-size: 22px; margin: 0; }
.landing__card .btn { width: 100%; }
.landing__ic { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 18px; background: var(--brand-soft); color: var(--brand); }
.landing__text { width: 100%; padding: 14px; border-radius: 12px; background: var(--surface-2); text-align: left; white-space: pre-wrap; word-break: break-word; max-height: 50vh; overflow: auto; }
.landing__big { font-size: 30px; font-weight: 800; letter-spacing: .02em; margin: 0; font-variant-numeric: tabular-nums; word-break: break-all; }
.landing__big--sm { font-size: 20px; }
.landing__by { margin-top: 18px; font-size: 13px; color: var(--ink-3); }
.landing .ad { width: 100%; max-width: 440px; }
.vcard { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.vcard__ava { display: grid; place-items: center; width: 76px; height: 76px; border-radius: 50%; background: linear-gradient(135deg, var(--brand), var(--brand-2)); color: #fff; font-size: 30px; font-weight: 800; margin-bottom: 6px; }
.vcard__role { color: var(--ink-2); margin: 0; }
.vcard__list { width: 100%; list-style: none; padding: 0; margin: 6px 0 0; text-align: left; }
.vcard__list li { display: flex; gap: 12px; align-items: center; padding: 12px 4px; border-top: 1px solid var(--line); word-break: break-word; }
.vcard__list .ic { color: var(--brand); }
.page-landing .landing__card ~ .landing__card { display: none; }

/* ── Chân trang ──────────────────────────────────────────────────────────── */
.site-foot { margin-top: 40px; padding: 40px 0 24px; background: var(--surface); border-top: 1px solid var(--line); }
.site-foot__in { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 28px; }
.site-foot__tag { color: var(--ink-2); font-size: 14px; margin-top: 12px; max-width: 340px; }
.site-foot__links { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 16px; align-content: start; }
.site-foot__links:last-child { grid-template-columns: 1fr; }
.site-foot__links a { color: var(--ink-2); font-size: 14px; }
.site-foot__copy { margin-top: 28px; color: var(--ink-3); font-size: 12.5px; }
@media (max-width: 760px) { .site-foot__in { grid-template-columns: minmax(0, 1fr); } }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
