h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}
/* ── BanHang Admin: cùng thế giới mực tối + vàng champagne với trang công khai, nhưng gọn và chính xác cho việc thao tác hằng ngày ──
   Bo góc: nút = viên thuốc (999px), ô nhập = 10px, khối/bảng = 16px. Chuyển động chỉ để phản hồi (bấm, rê, thông báo), không trang trí. */
:root {
    --bg: #0b0d12; --raise: #12151c; --card: rgba(255, 255, 255, .028); --fg: #ece8e1; --muted: #a39e94;
    --line: rgba(236, 232, 225, .08); --line-2: rgba(236, 232, 225, .16);
    --accent: #c9a96e; --accent-hi: #ead7ac; --ok: #9fd3b0; --warn: #e8c27a; --bad: #f3a6a9;
    --ease: cubic-bezier(.23, 1, .32, 1);
    color-scheme: dark;
}
* { box-sizing: border-box; }
html { background: var(--bg); scrollbar-color: rgba(236, 232, 225, .16) transparent; }
body { margin: 0; background: var(--bg); color: var(--fg); -webkit-font-smoothing: antialiased;
    font: 400 14.5px/1.55 "Be Vietnam Pro", system-ui, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; }
/* một quầng vàng rất mờ ở góc — giữ cảm giác "cùng nhà" với trang công khai */
body::before { content: ""; position: fixed; z-index: -1; top: -30vmax; right: -25vmax; width: 70vmax; height: 70vmax; pointer-events: none;
    background: radial-gradient(closest-side, rgba(176, 138, 74, .09), transparent); }
::selection { background: rgba(201, 169, 110, .32); color: #fff8ea; }
:focus-visible { outline: 1px solid var(--accent-hi); outline-offset: 2px; }
a { color: var(--accent-hi); text-decoration-color: rgba(201, 169, 110, .4); text-underline-offset: 3px; transition: color .2s; }
a:hover { color: #fff3d6; }
h1 { font: 500 clamp(1.7rem, 2.6vw, 2.2rem)/1.15 "Playfair Display", Georgia, "Songti SC", "SimSun", serif; letter-spacing: -.01em; margin: 0; text-wrap: balance; }
h1:focus { outline: none; }
h2 { font: 500 1.4rem/1.2 "Playfair Display", Georgia, "Songti SC", "SimSun", serif; margin: 3.2rem 0 1rem; }
h3 { font-size: 1.05rem; font-weight: 500; }
code { font: 12.5px ui-monospace, "Cascadia Mono", Consolas, monospace; color: var(--accent-hi); }
code.key { font-size: 13.5px; letter-spacing: .06em; user-select: all; }
b, strong { font-weight: 500; }
.muted { color: var(--muted); } .ok { color: var(--ok); } .warn { color: var(--warn); font-weight: 500; } .bad { color: var(--bad); font-weight: 500; }
.small { font-size: 13px; } .center { text-align: center; } .right { text-align: right; }

/* thanh trên cùng */
.top { position: sticky; top: 0; z-index: 30; display: flex; justify-content: space-between; align-items: center; gap: 1rem;
    padding: .85rem clamp(16px, 3vw, 32px); background: rgba(11, 13, 18, .74); border-bottom: 1px solid var(--line);
    backdrop-filter: blur(14px) saturate(140%); -webkit-backdrop-filter: blur(14px) saturate(140%); }
.top nav { display: flex; gap: 1.6rem; align-items: center; font-size: 13.5px; }
.top nav > a:not(.out) { position: relative; padding: .3rem 0; color: var(--muted); text-decoration: none; }
.top nav > a:not(.out):hover, .top nav > a.active { color: var(--fg); }
.top nav > a:not(.out)::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: var(--accent);
    transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.top nav > a.active::after { transform: scaleX(1); }
.top .who { padding-left: 1.6rem; border-left: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.top .out { padding: .4rem 1rem; border: 1px solid var(--line-2); border-radius: 999px; color: var(--fg); text-decoration: none; transition: border-color .2s, transform .16s var(--ease); }
.top .out:hover { border-color: var(--accent); color: var(--fg); }
.top .out:active { transform: scale(.97); }
.brand { display: inline-flex; align-items: center; gap: .6rem; font: 500 1.15rem "Playfair Display", Georgia, serif; color: var(--fg); text-decoration: none; }
.brand:hover { color: var(--fg); }
.brand small { font: 400 11px "Be Vietnam Pro", sans-serif; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.mark { display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--accent); border-radius: 50%; color: var(--accent); font-size: .85rem; font-style: italic; }

.page { max-width: 1180px; margin: 0 auto; padding: 2.4rem clamp(16px, 3vw, 32px) 4rem; animation: adm-in .45s var(--ease) both; }
.bar { display: flex; gap: .75rem 1rem; align-items: center; flex-wrap: wrap; margin-bottom: 1.6rem; }
.bar h1 { margin-right: auto; }
.bar > code { padding: .3rem .75rem; border: 1px solid rgba(201, 169, 110, .35); border-radius: 999px; letter-spacing: .06em; }
.page > p:first-child a { color: var(--muted); text-decoration: none; font-size: 13px; }
.page > p:first-child a:hover { color: var(--fg); }

/* khối, thông báo */
.card { margin: 1rem 0; padding: 1.25rem 1.4rem; border: 1px solid var(--line); border-radius: 16px;
    background: linear-gradient(160deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, .012)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .04); }
.note { padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 12px; background: var(--card); font-weight: 400; animation: adm-note .4s var(--ease) both; }
.note.ok { border-color: rgba(159, 211, 176, .28); background: rgba(159, 211, 176, .07); }
.note.bad { border-color: rgba(243, 166, 169, .3); background: rgba(243, 166, 169, .07); }

/* ô nhập + nút */
input, select, button { font: inherit; color: inherit; }
input, select { min-width: 0; padding: .5rem .75rem; border: 1px solid var(--line-2); border-radius: 10px; background: rgba(0, 0, 0, .28); color: var(--fg);
    font-variant-numeric: tabular-nums; transition: border-color .2s, box-shadow .2s, background-color .2s; }
input:hover, select:hover { border-color: rgba(236, 232, 225, .26); }
input:focus, select:focus { outline: none; border-color: var(--accent); background: rgba(0, 0, 0, .4); box-shadow: 0 0 0 3px rgba(201, 169, 110, .14); }
input::placeholder { color: #8c877e; }
select option { background: var(--raise); }
input:-webkit-autofill { -webkit-text-fill-color: var(--fg); -webkit-box-shadow: 0 0 0 40px #15171d inset; }
input.search { min-width: min(340px, 100%); padding: .55rem 1.1rem; border-radius: 999px; }
input.tiny { width: 4.75rem; }
input.name { width: 100%; min-width: 120px; background: transparent; border-color: transparent; }
input.name:hover { border-color: var(--line-2); }
input.name:focus { background: rgba(0, 0, 0, .4); border-color: var(--accent); }
button { padding: .45rem 1rem; border: 1px solid var(--line-2); border-radius: 999px; background: transparent; color: var(--fg); font-size: 13.5px; cursor: pointer;
    transition: border-color .2s, background-color .2s, box-shadow .25s, transform .16s var(--ease); }
button:active { transform: scale(.97); }
button.primary { border-color: var(--accent); background: linear-gradient(135deg, var(--accent-hi), var(--accent)); color: #17130b; font-weight: 500; }
button.bad { border-color: rgba(243, 166, 169, .5); background: rgba(243, 166, 169, .08); color: var(--bad); }
button:disabled { opacity: .4; cursor: not-allowed; transform: none; }
@media (hover: hover) {
    button:not(.primary):not(.bad):hover { border-color: var(--accent); background: rgba(201, 169, 110, .06); }
    button.primary:hover { box-shadow: 0 8px 24px -12px rgba(201, 169, 110, .6); }
}
label { display: flex; flex-direction: column; gap: .35rem; font-size: 12.5px; color: var(--muted); }
label > input, label > select { font-size: 14.5px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem 1.2rem; }
.form-grid .wide { grid-column: 1 / -1; }
.inline { display: flex; gap: .75rem 1rem; align-items: flex-end; flex-wrap: wrap; }
.inline > b { align-self: center; font-weight: 500; }

/* bảng */
table.grid { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--card); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.grid th, .grid td { padding: .75rem 1rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.grid tbody tr:last-child td { border-bottom: 0; }
.grid th { background: rgba(255, 255, 255, .02); color: var(--muted); font-size: 11.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; }
.grid td { font-variant-numeric: tabular-nums; }
.grid td.num, .grid th.num { text-align: right; }
.grid td small { opacity: .8; }
.grid tr.link { cursor: pointer; transition: background-color .15s; }
.grid tr.link b { transition: color .15s; }
.grid tr.link:hover { background: rgba(201, 169, 110, .05); }
.grid tr.link:hover b { color: var(--accent-hi); }
.grid tr.revoked td { opacity: .45; }
.grid tr.sub td { background: rgba(201, 169, 110, .035); }
.grid tr.sub .inline { animation: adm-note .3s var(--ease) both; }
.actions { white-space: nowrap; text-align: right; } .actions button { margin-left: .35rem; padding: .35rem .85rem; font-size: 12.5px; }
@media (max-width: 760px) {
    .grid { display: block; overflow-x: auto; }
    .top .who { display: none; }
    .top nav { gap: 1rem; }
}

@keyframes adm-in { from { opacity: 0; transform: translateY(6px); } }
@keyframes adm-note { from { opacity: 0; transform: translateY(-4px); } }
@media (prefers-reduced-motion: reduce) {
    .page, .note, .grid tr.sub .inline { animation: none; }
    *, *::after { transition-duration: 0s !important; }
}

/* ── Chọn ngôn ngữ (LangPicker) ── */
.langs { position: relative; }
.langs summary { display: flex; align-items: center; gap: .35rem; cursor: pointer; list-style: none; color: var(--muted); user-select: none; }
.langs summary::-webkit-details-marker { display: none; }
.langs summary:hover { color: var(--fg); }
.langs > div { position: absolute; right: 0; top: calc(100% + .6rem); z-index: 40; display: grid; min-width: 9rem; padding: .3rem;
    background: rgba(18, 21, 28, .97); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 24px 50px -20px rgba(0, 0, 0, .8);
    transform-origin: top right; animation: adm-pop .18s var(--ease) both; }
.langs > div a { padding: .45rem .75rem; border-radius: 8px; color: var(--fg); text-decoration: none; }
.langs > div a:hover { background: rgba(255, 255, 255, .04); }
.langs > div a.on { color: var(--accent-hi); }
@keyframes adm-pop { from { opacity: 0; transform: scale(.96) translateY(-4px); } }

/* ── Tab trên trang shop: đổi tab tức thì (thao tác lặp lại nhiều lần/ngày), chỉ màu chữ + vạch vàng chuyển mượt ── */
.tabs { display: flex; gap: 2rem; margin: .4rem 0 1.6rem; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tabs button[role=tab] { position: relative; flex: none; display: inline-flex; align-items: center; gap: .5rem; padding: .8rem 0 .9rem;
    border: 0; border-radius: 0; background: none; color: var(--muted); font-size: 14px; white-space: nowrap; transition: color .15s; }
.tabs button[role=tab]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1.5px; background: var(--accent);
    transform: scaleX(0); transition: transform .25s var(--ease); }
.tabs button[role=tab]:hover { color: var(--fg); background: none; border: 0; }
.tabs button[role=tab]:active { transform: none; }
.tabs button[role=tab].on { color: var(--fg); }
.tabs button[role=tab].on::after { transform: scaleX(1); }
.tabs .count { min-width: 1.5rem; padding: .05rem .45rem; border: 1px solid var(--line-2); border-radius: 999px; font-size: 11.5px; text-align: center;
    color: var(--muted); font-variant-numeric: tabular-nums; transition: color .15s, border-color .15s; }
.tabs .on .count { border-color: rgba(201, 169, 110, .45); color: var(--accent-hi); }
.tabpanel > .card:first-child, .tabpanel > .muted:first-child { margin-top: 0; }
.tabpanel > p.small:first-child { margin: 0 0 1rem; }
