@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@400;500;600;700&display=swap');
/* ============================================================
   AIWIBI Web — Design System (BOS-NEW FE)
   MOBILE-FIRST: base = mobile · @768px tablet · @1025px desktop
   Chuẩn theo file Figma: AIWIBI Web — FE Design
   ============================================================ */
:root {
  /* Brand */
  --primary: #1A274E;   /* AIWIBI Blue — Pantone 2767C */
  --primary-dark: #131D3B;
  --primary-deep: #0D1530;
  --mint: #E4EBF5;      /* nền dịu = tint 10% blue */
  --sky: #6E7BA1;       /* Blue 3 */
  --sky-light: #E7EDF6; /* Blue 9 nhạt */
  --cta: #D61518;       /* AIWIBI Red — Pantone 485C, accent ≤8% */
  --sale: #D61518;
  --gold: #E8A33D;      /* chỉ dùng cho sao đánh giá & hạng thành viên */
  --cream: #EEF3F9;
  /* Neutral */
  --n900: #1A274E;
  --n700: #414A70;      /* Blue 1 */
  --n500: #6E7BA1;      /* Blue 3 */
  --n300: #BAC7D8;      /* Blue 8 */
  --n100: #E7EDF6;
  --white: #FFFFFF;
  --bg: #F4F7FB;
  --pdark: #131D3B; --skyl: #E7EDF6;
  /* Layout */
  --container: 1200px;
  --r4: 4px; --r8: 8px; --r12: 12px; --pill: 999px;
  --shadow-sm: 0 1px 3px rgba(26,39,78,.08);
  --shadow-md: 0 4px 16px rgba(26,39,78,.10);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: 'Quicksand', 'Roboto', -apple-system, 'Segoe UI', Arial, sans-serif; color: var(--n900); background: var(--bg); font-size: 13.5px; line-height: 1.5; padding-bottom: 64px; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
img { max-width: 100%; display: block; }
.container { max-width: var(--container); margin: 0 auto; padding: 0 12px; }

/* Chống chữ mồ côi cuối dòng (orphan) — heading cân dòng, đoạn văn gom chữ lẻ */
h1, h2, h3, h4, .section-head h2, .page-title { text-wrap: balance; }
p, li, small, .p-name, .sub { text-wrap: pretty; }
.btn { white-space: nowrap; }

/* ============ HEADER (base: mobile) ============ */
.topbar { display: none; background: var(--primary-dark); color: rgba(255,255,255,.9); font-size: 12px; }
.topbar .container { display: flex; justify-content: space-between; align-items: center; height: 34px; }
.topbar-links { display: flex; gap: 20px; }
.topbar a:hover { color: #fff; }
.topbar .hotline { font-weight: 500; color: #fff; }

.mainbar { background: var(--primary); padding: 10px 0; }
.mainbar .container { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.logo { font-size: 22px; font-weight: 700; letter-spacing: -0.5px; color: #fff; display: flex; align-items: baseline; line-height: 1; }
.logo::after { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--cta); margin-left: 3px; }
.searchbar { order: 3; flex-basis: 100%; display: flex; align-items: center; background: #fff; border-radius: var(--pill); padding: 4px 4px 4px 14px; height: 40px; gap: 8px; }
.searchbar svg { flex: none; color: var(--n500); }
.searchbar input { flex: 1; border: none; outline: none; font-size: 14px; font-family: inherit; color: var(--n900); min-width: 0; }
.searchbar input::placeholder { color: var(--n500); }
.searchbar .search-btn { background: var(--primary); border-radius: var(--pill); width: 56px; height: 32px; display: flex; align-items: center; justify-content: center; color: #fff; flex: none; }
.header-actions { display: flex; align-items: center; gap: 16px; color: #fff; margin-left: auto; }
.h-action { display: flex; align-items: center; gap: 8px; }
.h-action .lines { display: none; flex-direction: column; line-height: 1.25; }
.h-action .lines .sub { font-size: 11.5px; opacity: .85; }
.h-action .lines .main { font-size: 13px; font-weight: 500; }
.cart-wrap { position: relative; }
.cart-badge { position: absolute; top: -6px; right: -8px; background: var(--cta); color: #fff; font-size: 10px; font-weight: 700; min-width: 18px; height: 18px; border-radius: var(--pill); display: flex; align-items: center; justify-content: center; border: 2px solid var(--primary); }

.navbar { background: #fff; border-bottom: 1px solid var(--n100); }
.navbar .container { display: flex; align-items: center; justify-content: space-between; height: 42px; gap: 12px; }
.nav-left { display: flex; align-items: center; gap: 18px; overflow-x: auto; scrollbar-width: none; }
.nav-left::-webkit-scrollbar { display: none; }
.cat-btn { display: flex; align-items: center; gap: 8px; background: var(--mint); color: var(--primary-dark); font-weight: 700; font-size: 13px; padding: 6px 12px; border-radius: var(--r8); white-space: nowrap; }
.nav-link { font-weight: 500; font-size: 13.5px; color: var(--n700); white-space: nowrap; }
.nav-link:hover, .nav-link.active { color: var(--primary); }
.nav-link.flash { color: #FF6B35; font-weight: 700; }
.nav-loc { display: none; align-items: center; gap: 6px; color: var(--n700); font-size: 12.5px; white-space: nowrap; }

/* ============ FOOTER ============ */
footer { background: var(--primary-deep); color: rgba(255,255,255,.75); margin-top: 40px; }
/* Mobile: brand + CSKH full hàng, "Về AIWIBI" và "Hỗ trợ KH" đứng cạnh nhau 2 cột */
.footer-main { display: grid; grid-template-columns: 1fr 1fr; gap: 26px 16px; padding: 32px 0 24px; }
.footer-brand { grid-column: 1 / -1; }
.footer-main > div:last-child { grid-column: 1 / -1; }
.footer-brand .logo { color: #fff; margin-bottom: 12px; }
.footer-brand p { font-size: 13px; line-height: 1.6; margin-bottom: 16px; }
.socials { display: flex; gap: 10px; }
.socials a { width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.12); display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 13px; }
footer h4 { color: #fff; font-size: 14px; margin-bottom: 12px; text-transform: uppercase; letter-spacing: .5px; }
footer li { margin-bottom: 9px; font-size: 13px; }
footer li a:hover { color: #fff; }
.footer-hotline { font-size: 20px; font-weight: 700; color: #fff; }
.pay-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pay-badges span { background: #fff; color: var(--n700); font-size: 11px; font-weight: 700; border-radius: var(--r4); padding: 4px 8px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.15); padding: 14px 0; font-size: 12px; }
.footer-bottom .container { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* ============ COMPONENTS ============ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 500; border-radius: var(--r8); transition: filter .15s; }
.btn:hover { filter: brightness(.95); }
.btn-primary { background: var(--primary); color: #fff; height: 44px; padding: 0 20px; font-size: 15px; }
.btn-cta { background: var(--cta); color: #fff; height: 48px; padding: 0 24px; font-size: 15.5px; font-weight: 700; }
.btn-outline { background: #fff; color: var(--primary); border: 1.5px solid var(--primary); height: 44px; padding: 0 20px; font-size: 15px; }
.btn-ghost { color: var(--n700); height: 40px; padding: 0 16px; }
.btn-sm { height: 34px; padding: 0 14px; font-size: 13px; border-radius: 6px; }
.btn-block { width: 100%; }

.badge { display: inline-flex; align-items: center; font-size: 11px; font-weight: 500; border-radius: var(--r4); padding: 2px 6px; }
.badge-discount { background: var(--sale); color: #fff; font-weight: 700; font-size: 12px; }
.badge-tag { background: var(--mint); color: var(--primary-dark); }
.badge-hot { background: var(--cta); color: #fff; font-weight: 700; }
.badge-info { background: var(--sky-light); color: var(--sky); }

.section { margin-top: 26px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; gap: 8px; }
.section-head h2 { font-size: 18px; font-weight: 700; }
.section-head .see-all { color: var(--primary); font-weight: 500; font-size: 13px; display: flex; align-items: center; gap: 4px; white-space: nowrap; }

/* Product card — base 2 cột mobile */
.product-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.product-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
.p-card { background: #fff; border: 1px solid var(--n100); border-radius: var(--r12); overflow: hidden; position: relative; transition: box-shadow .15s, transform .15s; display: flex; flex-direction: column; }
.p-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.p-img { aspect-ratio: 1; background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 48px; position: relative; }
.p-img.alt { background: var(--sky-light); }
.p-img.alt2 { background: var(--cream); }
.p-img .badge-discount { position: absolute; top: 8px; left: 8px; }
.p-fav { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; background: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--n500); box-shadow: var(--shadow-sm); }
.p-body { padding: 10px 10px 12px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.p-brand { font-size: 11px; font-weight: 500; letter-spacing: .06em; color: var(--primary); }
.p-name { font-size: 13px; line-height: 18px; height: 36px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.p-price { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.p-price .now { color: var(--sale); font-weight: 700; font-size: 15px; }
.p-price .old { color: var(--n500); font-size: 11.5px; text-decoration: line-through; }
.p-meta { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--n500); }
.stars { color: var(--gold); font-size: 11px; letter-spacing: 1px; }

/* Category tile — base 4 cột nhỏ */
.cat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.cat-tile { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.cat-tile .circle { width: 64px; height: 64px; border-radius: 50%; background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 26px; transition: transform .15s; }
.cat-tile:hover .circle { transform: scale(1.06); }
.cat-tile:nth-child(even) .circle { background: var(--sky-light); }
.cat-tile span { font-size: 11.5px; font-weight: 500; }

/* Service bar */
.service-bar { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; background: #fff; border-radius: var(--r12); padding: 14px; margin-top: 16px; }
.service-item { display: flex; align-items: center; gap: 10px; }
.service-item .ic { width: 42px; height: 42px; border-radius: 50%; background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 18px; flex: none; }
.service-item b { font-size: 13px; display: block; }
.service-item small { color: var(--n500); font-size: 11.5px; }

/* Hero */
.hero { display: grid; grid-template-columns: 1fr; gap: 10px; margin-top: 12px; }
.hero-main { border-radius: var(--r12); background: linear-gradient(120deg, var(--primary) 0%, #3A466E 60%, var(--sky) 100%); color: #fff; padding: 26px 22px; display: flex; flex-direction: column; justify-content: center; min-height: 210px; position: relative; overflow: hidden; }
.hero-main .kicker { font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; opacity: .9; margin-bottom: 8px; }
.hero-main h1 { font-size: 23px; line-height: 1.25; margin-bottom: 10px; max-width: 420px; }
.hero-main p { font-size: 13.5px; opacity: .92; margin-bottom: 18px; max-width: 380px; }
.hero-main .hero-emoji { position: absolute; right: 10px; bottom: 8px; font-size: 68px; opacity: .9; }
.hero-side { display: flex; flex-direction: column; gap: 10px; }
.hero-tile { flex: 1; border-radius: var(--r12); padding: 16px 18px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hero-tile b { font-size: 14.5px; display: block; margin-bottom: 2px; }
.hero-tile small { font-size: 12px; color: var(--n700); }
.hero-tile .em { font-size: 36px; }
.hero-tile.t1 { background: var(--cream); }
.hero-tile.t2 { background: var(--sky-light); }

/* Flash sale strip */
.flash-strip { background: linear-gradient(90deg,#FF6B35,#FF9245); border-radius: var(--r12); padding: 16px 14px; color: #fff; }
.flash-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.flash-head h2 { font-size: 18px; font-style: italic; }
.countdown { display: flex; gap: 4px; align-items: center; font-weight: 700; }
.countdown span { background: var(--n900); color: #fff; padding: 3px 6px; border-radius: 6px; font-size: 14px; min-width: 30px; text-align: center; }
.flash-strip .p-card { border: none; }

/* Brand strip */
.brand-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.brand-logo { background: #fff; border: 1px solid var(--n100); border-radius: var(--r12); height: 60px; display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--n700); font-size: 12.5px; text-align: center; padding: 0 6px; }

/* Breadcrumb */
.breadcrumb { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--n500); padding: 12px 0; flex-wrap: wrap; }
.breadcrumb .cur { color: var(--n900); font-weight: 500; }

/* ============ PLP — base: filter là bottom sheet ============ */
.plp-layout { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: start; }
.filters { display: none; }
body.filters-open .filters { display: block; position: fixed; left: 0; right: 0; bottom: 0; max-height: 78vh; overflow: auto; background: #fff; border-radius: 16px 16px 0 0; padding: 18px 16px calc(18px + 64px); z-index: 96; box-shadow: 0 -8px 30px rgba(21,39,48,.2); }
body.filters-open .filters-overlay { display: block; position: fixed; inset: 0; background: rgba(21,39,48,.45); z-index: 94; }
.filters-overlay { display: none; }
.filter-toggle { display: inline-flex; }
.filter-group { border-bottom: 1px solid var(--n100); padding: 14px 0; }
.filter-group:first-child { padding-top: 0; }
.filter-group:last-child { border-bottom: none; padding-bottom: 0; }
.filter-group h4 { font-size: 14px; margin-bottom: 10px; display: flex; justify-content: space-between; }
.filter-group label { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--n700); margin-bottom: 8px; cursor: pointer; }
.filter-group input[type="checkbox"] { accent-color: var(--primary); width: 16px; height: 16px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1px solid var(--n300); border-radius: var(--pill); padding: 5px 12px; font-size: 12.5px; color: var(--n700); cursor: pointer; white-space: nowrap; }
.chip.active { background: var(--mint); border-color: var(--primary); color: var(--primary-dark); font-weight: 500; }
.plp-toolbar { background: #fff; border-radius: var(--r12); padding: 10px 12px; display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; flex-wrap: wrap; gap: 10px; }
.plp-toolbar .count b { color: var(--primary); }
.sort-row { display: flex; gap: 8px; align-items: center; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.sort-row::-webkit-scrollbar { display: none; }
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 20px; }
.pagination a { width: 36px; height: 36px; border-radius: var(--r8); background: #fff; border: 1px solid var(--n100); display: flex; align-items: center; justify-content: center; font-size: 13.5px; color: var(--n700); }
.pagination a.cur { background: var(--primary); color: #fff; border-color: var(--primary); font-weight: 700; }

/* ============ PDP — base: 1 cột + CTA dính đáy ============ */
.pdp { display: grid; grid-template-columns: 1fr; gap: 18px; background: #fff; border-radius: var(--r12); padding: 14px; }
.gallery-main { aspect-ratio: 1; background: var(--mint); border-radius: var(--r12); display: flex; align-items: center; justify-content: center; font-size: 96px; position: relative; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 10px; }
.gallery-thumbs div { aspect-ratio: 1; background: var(--sky-light); border-radius: var(--r8); display: flex; align-items: center; justify-content: center; font-size: 24px; border: 2px solid transparent; cursor: pointer; }
.gallery-thumbs div.active { border-color: var(--primary); }
.pdp-info h1 { font-size: 19px; line-height: 1.3; margin: 6px 0 10px; }
.pdp-meta { display: flex; align-items: center; gap: 10px; color: var(--n500); font-size: 12.5px; margin-bottom: 14px; flex-wrap: wrap; }
.pdp-price { background: var(--bg); border-radius: var(--r12); padding: 12px 16px; display: flex; align-items: baseline; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.pdp-price .now { font-size: 26px; font-weight: 700; color: var(--sale); }
.pdp-price .old { font-size: 14px; color: var(--n500); text-decoration: line-through; }
.opt-group { margin-bottom: 16px; }
.opt-group h4 { font-size: 14px; margin-bottom: 8px; color: var(--n700); }
.opt-row { display: flex; gap: 8px; flex-wrap: wrap; }
.opt { border: 1.5px solid var(--n300); border-radius: var(--r8); padding: 8px 12px; font-size: 13px; cursor: pointer; background: #fff; }
.opt.active { border-color: var(--primary); background: var(--mint); color: var(--primary-dark); font-weight: 500; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--n300); border-radius: 6px; height: 40px; background: #fff; }
.qty button { width: 36px; height: 100%; font-size: 16px; color: var(--n700); }
.qty input { width: 44px; text-align: center; border: none; outline: none; font-size: 14px; font-weight: 500; font-family: inherit; }
.pdp-cta { display: flex; gap: 10px; position: fixed; left: 0; right: 0; bottom: 60px; background: #fff; padding: 10px 12px; box-shadow: 0 -4px 16px rgba(21,39,48,.12); z-index: 45; margin: 0; }
.pdp-cta .btn { padding: 0 10px; font-size: 14px; }
body[data-page="product"] { padding-bottom: 132px; }
.pdp-trust { border-top: 1px dashed var(--n300); padding-top: 14px; display: grid; grid-template-columns: 1fr; gap: 8px; font-size: 13px; color: var(--n700); }
.pdp-section { background: #fff; border-radius: var(--r12); padding: 16px; margin-top: 16px; }
.pdp-section h2 { font-size: 17px; margin-bottom: 12px; }
.spec-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.spec-table td { padding: 9px 10px; border-bottom: 1px solid var(--n100); }
.spec-table td:first-child { color: var(--n500); width: 40%; }
.review { border-bottom: 1px solid var(--n100); padding: 14px 0; }
.review-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; flex-wrap: wrap; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--sky-light); display: flex; align-items: center; justify-content: center; font-size: 16px; }
.review-score { background: var(--mint); border-radius: var(--r12); padding: 18px; text-align: center; }
.review-score .big { font-size: 40px; font-weight: 700; color: var(--primary-dark); }
.review-grid { display: grid; grid-template-columns: 1fr; gap: 18px; }

/* ============ CART / CHECKOUT ============ */
.page-title { font-size: 20px; font-weight: 700; margin: 16px 0 14px; }
.cart-layout { display: grid; grid-template-columns: minmax(0,1fr); gap: 16px; align-items: start; }
.cart-list { background: #fff; border-radius: var(--r12); overflow: hidden; }
/* mobile-first: 2 hàng — tránh bóp tên sản phẩm (ghi chú #15 căn chỉnh) */
.cart-line { display: grid; grid-template-columns: 64px minmax(0,1fr) auto; grid-template-areas: "thumb info trash" "thumb qty price"; column-gap: 10px; row-gap: 10px; align-items: center; padding: 12px; border-bottom: 1px solid var(--n100); }
.cart-line > .cart-thumb { grid-area: thumb; align-self: start; }
.cart-line > .cart-info { grid-area: info; }
.cart-line > .qty { grid-area: qty; justify-self: start; }
.cart-line > .cart-price { grid-area: price; }
.cart-line > .trash { grid-area: trash; align-self: start; }
.cart-line:last-child { border-bottom: none; }
.cart-thumb { width: 64px; height: 64px; border-radius: var(--r8); background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 30px; flex: none; }
.cart-info { flex: 1; min-width: 0; }
.cart-info .name { font-weight: 500; margin-bottom: 2px; font-size: 13.5px; }
.cart-info .variant { font-size: 12px; color: var(--n500); margin-bottom: 4px; }
.cart-price { text-align: right; }
.cart-price .now { color: var(--sale); font-weight: 700; font-size: 14.5px; }
.cart-price .old { color: var(--n500); font-size: 12px; text-decoration: line-through; }
.trash { color: var(--n500); font-size: 16px; }
.summary { background: #fff; border-radius: var(--r12); padding: 16px; }
.summary h3 { font-size: 16px; margin-bottom: 14px; }
.sum-row { display: flex; justify-content: space-between; font-size: 13.5px; margin-bottom: 10px; color: var(--n700); gap: 10px; }
.sum-row.total { border-top: 1px dashed var(--n300); padding-top: 12px; margin-top: 12px; font-size: 15px; color: var(--n900); font-weight: 500; }
.sum-row.total .val { font-size: 21px; font-weight: 700; color: var(--sale); }
.sum-row .green { color: var(--primary); }
.promo-input { display: flex; gap: 8px; margin: 12px 0; }
.promo-input input { flex: 1; border: 1px solid var(--n300); border-radius: var(--r8); padding: 0 12px; height: 40px; font-family: inherit; outline: none; min-width: 0; }
.stepper { display: flex; align-items: center; gap: 8px; margin: 18px 0 14px; flex-wrap: wrap; }
.step { display: flex; align-items: center; gap: 8px; }
.step .num { width: 28px; height: 28px; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; }
.step.pending .num { background: #fff; border: 1.5px solid var(--n300); color: var(--n500); }
.step span { font-weight: 500; font-size: 13px; }
.step.pending span { color: var(--n500); }
.step-line { width: 28px; height: 2px; background: var(--primary); border-radius: 2px; }
.step-line.pending { background: var(--n300); }
.card { background: #fff; border-radius: var(--r12); padding: 16px; margin-bottom: 14px; }
.card h3 { font-size: 15.5px; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.form-grid { display: grid; grid-template-columns: minmax(0,1fr); gap: 12px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 13px; font-weight: 500; color: var(--n700); margin-bottom: 6px; }
.field input, .field select, .field textarea { width: 100%; border: 1px solid var(--n300); border-radius: var(--r8); height: 44px; padding: 0 14px; font-size: 14px; font-family: inherit; outline: none; background: #fff; color: var(--n900); }
.field textarea { height: 80px; padding: 10px 14px; resize: vertical; }
.field input:focus, .field select:focus { border-color: var(--primary); }
.radio-card { display: flex; align-items: center; gap: 10px; border: 1.5px solid var(--n300); border-radius: var(--r8); padding: 11px 12px; margin-bottom: 10px; cursor: pointer; flex-wrap: wrap; }
.radio-card.active { border-color: var(--primary); background: var(--mint); }
.radio-card input { accent-color: var(--primary); width: 18px; height: 18px; }
.radio-card .em { font-size: 20px; }
.radio-card b { font-size: 13.5px; display: block; }
.radio-card small { color: var(--n500); font-size: 12px; }
.radio-card .price-right { margin-left: auto; font-weight: 500; font-size: 13px; }

/* ============ AUTH ============ */
.auth-wrap { max-width: 420px; margin: 24px auto; background: #fff; border-radius: var(--r12); padding: 22px 18px; box-shadow: var(--shadow-sm); }
.auth-wrap h1 { font-size: 20px; text-align: center; margin-bottom: 6px; }
.auth-wrap .sub { text-align: center; color: var(--n500); font-size: 13px; margin-bottom: 20px; }
.otp-row { display: flex; gap: 8px; justify-content: center; margin: 16px 0; }
.otp-row input { width: 46px; height: 52px; text-align: center; font-size: 22px; font-weight: 700; border: 1.5px solid var(--n300); border-radius: var(--r8); outline: none; font-family: inherit; }
.otp-row input:focus { border-color: var(--primary); }
.divider { display: flex; align-items: center; gap: 12px; color: var(--n500); font-size: 12px; margin: 18px 0; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--n100); }
.social-login { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.social-login .btn { border: 1px solid var(--n300); background: #fff; color: var(--n900); font-size: 13px; height: 42px; }

/* ============ ACCOUNT ============ */
.account-layout { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: start; margin-top: 16px; }
.acc-side { background: #fff; border-radius: var(--r12); overflow: hidden; }
.acc-user { background: linear-gradient(120deg, var(--primary), #3A466E); color: #fff; padding: 16px; display: flex; gap: 12px; align-items: center; }
.acc-user .avatar { width: 44px; height: 44px; font-size: 20px; background: rgba(255,255,255,.25); }
.acc-user b { display: block; font-size: 14.5px; }
.acc-user small { opacity: .9; font-size: 12px; }
.acc-menu { display: flex; overflow-x: auto; scrollbar-width: none; }
.acc-menu::-webkit-scrollbar { display: none; }
.acc-menu li { flex: none; }
.acc-menu li a { display: flex; align-items: center; gap: 8px; padding: 11px 14px; font-size: 13px; color: var(--n700); border-bottom: 3px solid transparent; white-space: nowrap; }
.acc-menu li a.active { background: var(--mint); color: var(--primary-dark); font-weight: 500; border-bottom-color: var(--primary); }
.loyalty-card { border-radius: var(--r12); background: linear-gradient(120deg, var(--primary-deep), var(--primary)); color: #fff; padding: 18px; display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; flex-wrap: wrap; gap: 14px; }
.loyalty-card .tier { font-size: 18px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.loyalty-card .points b { font-size: 24px; }
.progress { height: 8px; background: rgba(255,255,255,.25); border-radius: var(--pill); overflow: hidden; margin-top: 10px; width: 100%; }
.progress i { display: block; height: 100%; width: 64%; background: var(--gold); border-radius: var(--pill); }
.stat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
.stat { background: #fff; border-radius: var(--r12); padding: 14px; text-align: center; }
.stat b { font-size: 19px; color: var(--primary-dark); display: block; }
.stat small { color: var(--n500); font-size: 11.5px; }
.order-row { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--n100); flex-wrap: wrap; }
.order-row:last-child { border-bottom: none; }
.order-status { font-size: 12px; font-weight: 500; border-radius: var(--pill); padding: 3px 10px; }
.st-shipping { background: var(--sky-light); color: var(--sky); }
.st-done { background: var(--mint); color: var(--primary-dark); }
.st-cancel { background: #F8ECEC; color: var(--sale); }
.st-pending { background: var(--cream); color: #B7791F; }
.timeline { position: relative; padding-left: 26px; }
.timeline::before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--n100); }
.tl-item { position: relative; padding-bottom: 16px; font-size: 13px; }
.tl-item::before { content: ""; position: absolute; left: -24px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--n300); border: 2px solid #fff; }
.tl-item.done::before { background: var(--primary); }
.tl-item b { display: block; }
.tl-item small { color: var(--n500); }
.voucher-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.voucher { display: flex; background: #fff; border: 1.5px solid var(--mint); border-radius: var(--r12); overflow: hidden; }
.voucher .amount { width: 78px; background: var(--primary); color: #fff; font-weight: 700; font-size: 19px; display: flex; align-items: center; justify-content: center; flex: none; }
.voucher.expired .amount { background: var(--n300); }
.voucher .v-body { padding: 12px; flex: 1; }
.voucher .v-body b { font-size: 13.5px; display: block; }
.voucher .v-body small { color: var(--n500); font-size: 11.5px; display: block; margin: 3px 0 8px; }

/* ============ CONTENT PAGES ============ */
.blog-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.blog-card { background: #fff; border: 1px solid var(--n100); border-radius: var(--r12); overflow: hidden; display: flex; flex-direction: column; }
.blog-card .thumb { height: 150px; background: var(--sky-light); display: flex; align-items: center; justify-content: center; font-size: 48px; }
.blog-card .b-body { padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.blog-card h3 { font-size: 15.5px; line-height: 1.35; }
.blog-card p { font-size: 13px; color: var(--n500); }
.blog-card .meta { font-size: 12px; color: var(--n500); }
.article { background: #fff; border-radius: var(--r12); padding: 20px 16px; max-width: 820px; margin: 0 auto; }
.article h1 { font-size: 22px; line-height: 1.3; margin: 12px 0; }
.article .a-meta { color: var(--n500); font-size: 13px; margin-bottom: 18px; }
.article p { font-size: 15px; line-height: 1.75; color: var(--n700); margin-bottom: 14px; }
.article h2 { font-size: 18px; margin: 20px 0 10px; }
.article .a-img { border-radius: var(--r12); background: var(--mint); height: 200px; display: flex; align-items: center; justify-content: center; font-size: 64px; margin: 16px 0; }
.store-layout { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: start; }
.store-item { padding: 12px 14px; border-bottom: 1px solid var(--n100); cursor: pointer; }
.store-item:hover, .store-item.active { background: var(--mint); }
.store-item b { display: block; font-size: 14px; }
.store-item small { color: var(--n500); font-size: 12.5px; }
.map-ph { background: var(--sky-light); border-radius: var(--r12); min-height: 260px; display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 8px; color: var(--sky); font-weight: 500; }
.map-ph .em { font-size: 52px; }
.hero-page { border-radius: var(--r12); background: linear-gradient(120deg, var(--primary) 0%, #3A466E 70%, var(--sky) 100%); color: #fff; padding: 30px 22px; margin-top: 12px; }
.hero-page h1 { font-size: 23px; margin-bottom: 10px; }
.hero-page p { max-width: 560px; opacity: .93; font-size: 14px; }
.value-grid { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 16px; }
.value-card { background: #fff; border-radius: var(--r12); padding: 18px; }
.value-card .em { font-size: 34px; margin-bottom: 8px; }
.value-card h3 { font-size: 16px; margin-bottom: 6px; }
.value-card p { color: var(--n500); font-size: 13px; }
.contact-layout { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 16px; align-items: start; }

/* ============ MOBILE TABBAR (base: hiện) ============ */
.m-tabbar { display: flex; position: fixed; bottom: 0; left: 0; right: 0; background: #fff; border-top: 1px solid var(--n100); z-index: 50; height: 60px; }
.m-tabbar a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 10.5px; color: var(--n500); }
.m-tabbar a.active { color: var(--primary); font-weight: 500; }
.m-tabbar .em { font-size: 20px; }

/* ============ Mega menu ============ */
.cat-wrap { position: relative; }
.mega { display: none; position: absolute; top: calc(100% + 7px); left: 0; z-index: 40; background: #fff; border-radius: 0 12px 12px 12px; box-shadow: var(--shadow-md); width: min(94vw, 780px); padding: 18px; grid-template-columns: 1fr 1fr; gap: 16px; }
.cat-wrap:hover .mega, .cat-wrap.open .mega { display: grid; }
.cat-wrap::after { content: ""; position: absolute; top: 100%; left: 0; right: 0; height: 8px; }
.mega h5 { font-size: 12.5px; color: var(--primary-dark); margin-bottom: 8px; text-transform: uppercase; letter-spacing: .04em; }
.mega a { display: block; font-size: 13px; color: var(--n700); padding: 4px 0; }
.mega a:hover { color: var(--primary); }
.mega .mega-banner { background: var(--cream); border-radius: 10px; padding: 14px; font-size: 13px; }

/* ============ Smart search suggest ============ */
.searchbar { position: relative; }
.search-suggest { display: none; position: absolute; top: calc(100% + 6px); left: 0; right: 0; background: #fff; border-radius: 12px; box-shadow: var(--shadow-md); padding: 12px 14px; z-index: 60; color: var(--n900); }
.searchbar:focus-within .search-suggest, .searchbar.open .search-suggest { display: block; }
.ss-fix { font-size: 13px; background: var(--mint); border-radius: 8px; padding: 8px 10px; margin-bottom: 10px; }
.ss-label { font-size: 11px; color: var(--n500); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 6px; }
.ss-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.ss-item { display: flex; gap: 10px; align-items: center; padding: 6px 4px; border-radius: 8px; }
.ss-item:hover { background: var(--bg); }
.ss-item .th { width: 40px; height: 40px; border-radius: 8px; background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 20px; flex: none; }
.ss-item b { font-size: 13px; display: block; }
.ss-item small { color: var(--sale); font-weight: 700; }

/* ============ Slide cart (mini cart drawer) ============ */
.drawer-overlay { display: none; position: fixed; inset: 0; background: rgba(21,39,48,.45); z-index: 90; }
.mini-cart { position: fixed; top: 0; right: -400px; width: min(380px, 92vw); height: 100vh; background: #fff; z-index: 95; display: flex; flex-direction: column; transition: right .25s; box-shadow: -8px 0 30px rgba(21,39,48,.18); }
body.cart-open .mini-cart { right: 0; }
body.cart-open .drawer-overlay { display: block; }
.mini-cart .mc-head { display: flex; align-items: center; justify-content: space-between; padding: 16px; border-bottom: 1px solid var(--n100); font-weight: 700; font-size: 16px; }
.mini-cart .mc-body { flex: 1; overflow: auto; padding: 0 16px; }
.mini-cart .mc-foot { border-top: 1px solid var(--n100); padding: 14px 16px; }
.mc-close { font-size: 20px; color: var(--n500); cursor: pointer; }

/* ============ Progress freeship & quà tặng ============ */
.gift-progress { background: var(--mint); border-radius: 10px; padding: 12px 14px; margin-bottom: 14px; font-size: 12.5px; }
.gift-progress .gp-bar { height: 8px; background: #fff; border-radius: 999px; margin: 8px 0 6px; position: relative; }
.gift-progress .gp-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), #3A466E); border-radius: 999px; }
.gift-progress .gp-marks { display: flex; justify-content: space-between; color: var(--n700); }
.gift-progress .ok { color: var(--primary-dark); font-weight: 700; }

/* ============ Chat widget AI ============ */
.chat-bubble { position: fixed; right: 14px; bottom: 76px; width: 54px; height: 54px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 25px; box-shadow: var(--shadow-md); cursor: pointer; z-index: 80; border: none; }
body[data-page="product"] .chat-bubble { bottom: 144px; }
.chat-panel { display: none; position: fixed; right: 14px; bottom: 140px; width: min(340px, 92vw); background: #fff; border-radius: 14px; box-shadow: var(--shadow-md); z-index: 85; overflow: hidden; }
body.chat-open .chat-panel { display: block; }
.chat-panel .ch-head { background: var(--primary); color: #fff; padding: 12px 16px; font-weight: 700; font-size: 14px; }
.chat-panel .ch-head small { display: block; font-weight: 400; font-size: 11.5px; opacity: .9; }
.chat-panel .ch-body { padding: 14px; max-height: 280px; overflow: auto; display: flex; flex-direction: column; gap: 8px; }
.msg { max-width: 85%; padding: 8px 12px; border-radius: 12px; font-size: 13px; line-height: 1.45; }
.msg.bot { background: var(--bg); border-top-left-radius: 4px; }
.msg.user { background: var(--mint); align-self: flex-end; border-top-right-radius: 4px; }
.ch-quick { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 10px; }
.ch-input { display: flex; gap: 8px; border-top: 1px solid var(--n100); padding: 10px 14px; }
.ch-input input { flex: 1; border: none; outline: none; font-size: 13px; font-family: inherit; }

/* ============ Vòng quay may mắn ============ */
.wheel-wrap { display: flex; gap: 28px; align-items: center; justify-content: center; flex-wrap: wrap; }
.wheel { width: 260px; height: 260px; border-radius: 50%; position: relative; border: 10px solid #fff; box-shadow: var(--shadow-md); background: conic-gradient(var(--primary) 0 45deg, var(--mint) 45deg 90deg, var(--cta) 90deg 135deg, var(--sky-light) 135deg 180deg, var(--gold) 180deg 225deg, var(--mint) 225deg 270deg, var(--sale) 270deg 315deg, var(--sky-light) 315deg 360deg); }
.wheel-center { position: absolute; inset: 0; margin: auto; width: 78px; height: 78px; border-radius: 50%; background: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--primary-dark); box-shadow: var(--shadow-sm); font-size: 14px; }
.wheel-pointer { position: absolute; top: -18px; left: 50%; transform: translateX(-50%); font-size: 30px; }

/* ============ Growth tracker ============ */
.growth-chart { background: #fff; border-radius: 12px; padding: 12px; }
.growth-chart svg { width: 100%; height: auto; }
.milestone { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; border-bottom: 1px dashed var(--n100); font-size: 13px; flex-wrap: wrap; }
.milestone:last-child { border-bottom: none; }
.milestone .em { font-size: 20px; }

/* ============ Bundle mua kèm ============ */
.bundle { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; background: var(--cream); border-radius: 12px; padding: 14px; }
.bundle .b-item { width: 76px; text-align: center; font-size: 11px; color: var(--n700); }
.bundle .b-item .th { width: 64px; height: 64px; margin: 0 auto 6px; border-radius: 10px; background: #fff; display: flex; align-items: center; justify-content: center; font-size: 28px; }
.bundle .plus { font-size: 18px; color: var(--n500); font-weight: 700; }
.bundle .b-total { margin-left: auto; text-align: right; }

/* ============================================================
   ≥ 768px — TABLET
   ============================================================ */
@media (min-width: 768px) {
  body { font-size: 14px; padding-bottom: 0; }
  .container { padding: 0 16px; }
  .m-tabbar { display: none; }
  .topbar { display: block; }
  .mainbar { padding: 12px 0; }
  .mainbar .container { flex-wrap: nowrap; gap: 20px; }
  .logo { font-size: 26px; }
  .searchbar { order: 0; flex-basis: auto; flex: 1; height: 44px; padding-left: 18px; }
  .searchbar .search-btn { width: 64px; height: 36px; }
  .header-actions { gap: 20px; margin-left: 0; }
  .h-action .lines { display: flex; }
  .navbar .container { height: 46px; }
  .chat-bubble { bottom: 20px; right: 20px; }
  body[data-page="product"] .chat-bubble { bottom: 20px; }
  .chat-panel { bottom: 88px; right: 20px; }
  body[data-page="product"] { padding-bottom: 0; }
  .pdp-cta { position: static; box-shadow: none; padding: 0; margin: 18px 0; }
  .pdp-cta .btn { padding: 0 24px; font-size: 15px; }
  .footer-brand, .footer-main > div:last-child { grid-column: auto; }

  .section { margin-top: 30px; }
  .section-head h2 { font-size: 20px; }
  .page-title { font-size: 22px; }
  .product-grid, .product-grid.cols-4 { grid-template-columns: repeat(3, 1fr); gap: 12px; }
  .p-img { font-size: 52px; }
  .p-name { font-size: 13.5px; line-height: 19px; height: 38px; }
  .cat-row { grid-template-columns: repeat(4, 1fr); gap: 12px; }
  .cat-tile .circle { width: 80px; height: 80px; font-size: 32px; }
  .cat-tile span { font-size: 13px; }
  .service-bar { padding: 16px 20px; gap: 14px; }
  .brand-strip { grid-template-columns: repeat(3, 1fr); }
  .hero-main { padding: 40px 36px; min-height: 280px; }
  .hero-main h1 { font-size: 30px; }
  .hero-main .hero-emoji { font-size: 104px; right: 24px; }
  .hero-side { flex-direction: row; }
  .flash-strip { padding: 20px 22px; }
  .flash-head h2 { font-size: 21px; }

  .form-grid { grid-template-columns: minmax(0,1fr) minmax(0,1fr); }
  .stat-grid { grid-template-columns: repeat(4, 1fr); }
  .voucher-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-grid { grid-template-columns: repeat(2, 1fr); }
  .value-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-main { grid-template-columns: 1fr 1fr; gap: 36px; padding: 44px 0 32px; }
  .social-login { grid-template-columns: repeat(3, 1fr); }
  .auth-wrap { padding: 32px; margin: 40px auto; }
  .article { padding: 30px 36px; }
  .article h1 { font-size: 27px; }
  .article .a-img { height: 300px; font-size: 84px; }
  .hero-page { padding: 48px 44px; }
  .hero-page h1 { font-size: 30px; }
  .map-ph { min-height: 400px; }
  .acc-menu { display: block; overflow: visible; }
  .acc-menu li a { border-bottom: none; border-left: 3px solid transparent; padding: 12px 20px; font-size: 14px; }
  .acc-menu li a.active { border-left-color: var(--primary); }
  .wheel { width: 320px; height: 320px; }
  .wheel-center { width: 84px; height: 84px; font-size: 15px; }
  .step-line { width: 56px; }
  .pdp { padding: 20px; }
  .pdp-info h1 { font-size: 22px; }
  .pdp-price .now { font-size: 30px; }
  .pdp-trust { grid-template-columns: 1fr 1fr; }
  .pdp-section { padding: 22px; }
  .pdp-section h2 { font-size: 19px; }
  .spec-table td:first-child { width: 220px; }
  .gallery-main { font-size: 130px; }
  .cart-line { display: flex; align-items: center; padding: 16px; gap: 16px; flex-wrap: nowrap; }
  .cart-thumb { width: 80px; height: 80px; font-size: 36px; }
  .mega { grid-template-columns: 1fr 1fr 1fr 210px; padding: 20px; }
}

/* ============================================================
   ≥ 1025px — DESKTOP
   ============================================================ */
@media (min-width: 1025px) {
  .nav-loc { display: flex; }
  .searchbar { max-width: 620px; }
  .product-grid { grid-template-columns: repeat(5, 1fr); }
  .product-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
  .cat-row { grid-template-columns: repeat(8, 1fr); }
  .cat-tile .circle { width: 88px; height: 88px; font-size: 36px; }
  .service-bar { grid-template-columns: repeat(4, 1fr); }
  .brand-strip { grid-template-columns: repeat(6, 1fr); }
  .hero { grid-template-columns: 2fr 1fr; gap: 12px; }
  .hero-main { padding: 48px; min-height: 320px; }
  .hero-main h1 { font-size: 34px; }
  .hero-main .hero-emoji { font-size: 130px; right: 36px; bottom: 16px; }
  .hero-side { flex-direction: column; }
  .section-head h2 { font-size: 22px; }
  .page-title { font-size: 24px; }

  /* PLP: sidebar filter quay lại, tắt bottom sheet */
  .plp-layout { grid-template-columns: 250px 1fr; gap: 20px; }
  .filters { display: block; background: #fff; border-radius: var(--r12); padding: 18px; position: sticky; top: 16px; }
  body.filters-open .filters { position: sticky; left: auto; right: auto; bottom: auto; max-height: none; overflow: visible; border-radius: var(--r12); padding: 18px; box-shadow: none; z-index: 1; }
  body.filters-open .filters-overlay { display: none; }
  .filter-toggle { display: none; }
  .sort-row { flex-wrap: wrap; overflow: visible; }

  .pdp { grid-template-columns: 480px 1fr; gap: 32px; padding: 24px; }
  .pdp-info h1 { font-size: 24px; }
  .pdp-price .now { font-size: 32px; }
  .gallery-main { font-size: 150px; }
  .review-grid { grid-template-columns: 240px 1fr; gap: 24px; }
  .cart-layout { grid-template-columns: minmax(0,1fr) 360px; gap: 20px; }
  .summary { position: sticky; top: 16px; padding: 20px; }
  .account-layout { grid-template-columns: 280px 1fr; gap: 20px; }
  .store-layout { grid-template-columns: 400px 1fr; gap: 20px; }
  .map-ph { min-height: 520px; }
  .contact-layout { grid-template-columns: 1fr 1.2fr; gap: 20px; }
  .voucher-grid { grid-template-columns: repeat(3, 1fr); }
  .blog-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-main { grid-template-columns: 1.5fr 1fr 1fr 1fr 1.1fr; gap: 34px; padding: 48px 0 36px; }
  .article { padding: 32px 40px; }
  .article h1 { font-size: 30px; }
  .hero-page { padding: 56px 48px; }
  .hero-page h1 { font-size: 34px; }
  .blog-card .thumb { height: 170px; font-size: 56px; }
}

/* ==================================================================
   B2B PORTAL ĐẠI LÝ  —  mobile-first, nâng cấp ở >=768 và >=1025
   ================================================================== */
.b2b-side .acc-user { background: linear-gradient(120deg,#7A4E00,#E8A33D); }
.b2b-bar { background: var(--primary-deep); color: #fff; }
.b2b-bar .container { display: flex; align-items: center; gap: 10px; padding-top: 8px; padding-bottom: 8px; flex-wrap: wrap; font-size: 12px; }
.b2b-bar b { font-size: 13px; }
.b2b-bar .sep { opacity: .35; }
.b2b-bar .warn { background: var(--sale); border-radius: var(--pill); padding: 2px 10px; font-weight: 700; font-size: 11px; }

.kpi-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; }
.kpi { background: #fff; border-radius: var(--r12); padding: 13px; }
.kpi .lab { color: var(--n500); font-size: 11.5px; display: block; }
.kpi .val { font-size: 20px; font-weight: 700; color: var(--n900); display: block; line-height: 1.25; margin-top: 2px; }
.kpi .val.up { color: var(--primary); }
.kpi .val.down { color: var(--sale); }
.kpi .sub { font-size: 11px; color: var(--n500); }

/* Bảng dữ liệu: mobile = card xếp dọc, desktop = bảng thật */
.dtable-wrap { background: #fff; border-radius: var(--r12); overflow: hidden; }
.dtable { width: 100%; border-collapse: collapse; font-size: 13px; }
.dtable thead { display: none; }
.dtable tbody tr { display: block; border-bottom: 1px solid var(--n100); padding: 12px 14px; }
.dtable tbody tr:last-child { border-bottom: none; }
.dtable td { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; border: none; align-items: baseline; }
.dtable td::before { content: attr(data-l); color: var(--n500); font-size: 11.5px; flex: none; }
.dtable td.main { font-weight: 700; font-size: 13.5px; padding-bottom: 6px; }
.dtable td.main::before { content: none; }
.dtable td.num { font-variant-numeric: tabular-nums; }
.dtable .rowact { padding-top: 8px; gap: 8px; }
.dtable .rowact::before { content: none; }

.tbl-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-bottom: 1px solid var(--n100); }
.tbl-head h3 { font-size: 15px; }
.tbl-head .right { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.tag { display: inline-flex; align-items: center; gap: 4px; border-radius: 6px; padding: 3px 8px; font-size: 11px; font-weight: 500; background: var(--n100); color: var(--n700); }
.tag-ok { background: var(--mint); color: var(--primary-dark); }
.tag-warn { background: var(--cream); color: #B7791F; }
.tag-bad { background: #F8ECEC; color: var(--sale); }
.tag-info { background: var(--sky-light); color: var(--sky); }
.tag-cta { background: #F8ECEC; color: #C1440E; }

.b2b-alert { display: flex; gap: 10px; border-radius: var(--r12); padding: 12px 14px; font-size: 12.5px; line-height: 1.5; }
.b2b-alert .em { font-size: 18px; line-height: 1; }
.al-warn { background: var(--cream); color: #7A4E00; }
.al-bad { background: #F8ECEC; color: #9B1B30; }
.al-ok { background: var(--mint); color: var(--primary-deep); }
.al-info { background: var(--sky-light); color: #414A70; }

.aging { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; }
.aging .ag { border-radius: var(--r12); padding: 12px; color: #fff; }
.ag-0 { background: var(--primary); } .ag-1 { background: var(--gold); }
.ag-2 { background: var(--cta); } .ag-3 { background: var(--sale); }
.aging .ag b { display: block; font-size: 17px; }
.aging .ag small { opacity: .9; font-size: 11px; }

.credit-bar { height: 12px; border-radius: var(--pill); background: var(--n100); overflow: hidden; display: flex; }
.credit-bar i { display: block; height: 100%; }
.credit-bar .used { background: var(--cta); }
.credit-bar .over { background: var(--sale); }

.tier-row { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--n100); }
.tier-row:last-child { border-bottom: none; }
.tier-row.on { background: var(--mint); margin: 0 -14px; padding: 11px 14px; border-radius: var(--r8); }
.tier-row .pct { margin-left: auto; font-weight: 700; color: var(--primary); }

.wizard { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.wizard::-webkit-scrollbar { display: none; }
.wz { flex: none; display: flex; align-items: center; gap: 7px; background: #fff; border-radius: var(--pill); padding: 8px 13px; font-size: 12px; color: var(--n500); border: 1px solid var(--n100); }
.wz b { width: 20px; height: 20px; border-radius: 50%; background: var(--n100); color: var(--n500); display: flex; align-items: center; justify-content: center; font-size: 11px; }
.wz.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.wz.on b { background: rgba(255,255,255,.28); color: #fff; }
.wz.done { border-color: var(--primary); color: var(--primary-dark); }
.wz.done b { background: var(--primary); color: #fff; }

.drop { border: 2px dashed var(--n300); border-radius: var(--r12); padding: 22px 14px; text-align: center; color: var(--n500); font-size: 12.5px; background: #fff; }
.drop .em { font-size: 26px; display: block; margin-bottom: 6px; }

.file-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--n100); }
.file-row:last-child { border-bottom: none; }
.file-row .ic { width: 36px; height: 36px; border-radius: var(--r8); background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 16px; flex: none; }
.file-row .fi { flex: 1; min-width: 0; }
.file-row .fi b { display: block; font-size: 13px; }
.file-row .fi small { color: var(--n500); font-size: 11px; }

.qty-b2b { display: flex; align-items: center; gap: 6px; }
.qty-b2b input { width: 54px; height: 34px; text-align: center; border: 1px solid var(--n300); border-radius: var(--r8); font-family: inherit; font-size: 13px; }
.qty-b2b .unit { font-size: 11.5px; color: var(--n500); }

.bars { display: flex; flex-direction: column; gap: 9px; }
.bars .b { display: grid; grid-template-columns: 92px 1fr auto; gap: 9px; align-items: center; font-size: 12px; }
.bars .track { height: 10px; border-radius: var(--pill); background: var(--n100); overflow: hidden; }
.bars .track i { display: block; height: 100%; border-radius: var(--pill); background: var(--primary); }
.bars .b.alt .track i { background: var(--sky); }
.bars .val { font-weight: 700; font-variant-numeric: tabular-nums; }

.chart-col { display: flex; align-items: flex-end; gap: 7px; height: 150px; padding: 10px 0; }
.chart-col .c { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 5px; height: 100%; }
.chart-col .c i { display: block; width: 100%; border-radius: 6px 6px 0 0; background: linear-gradient(180deg, var(--primary), #3A466E); }
.chart-col .c.now i { background: linear-gradient(180deg, var(--cta), #F0524E); }
.chart-col .c small { font-size: 10px; color: var(--n500); }

.terr-map { position: relative; height: 210px; border-radius: var(--r12); background: var(--sky-light); overflow: hidden; }
.terr-map .zone { position: absolute; border-radius: 50%; }
.terr-map .lb { position: absolute; background: #fff; border-radius: var(--pill); padding: 4px 10px; font-size: 11px; font-weight: 500; box-shadow: 0 2px 8px rgba(21,39,48,.12); }

.notice { display: flex; gap: 11px; padding: 13px 0; border-bottom: 1px solid var(--n100); }
.notice:last-child { border-bottom: none; }
.notice .ic { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 15px; flex: none; background: var(--mint); }
.notice .nb { flex: 1; min-width: 0; }
.notice .nb b { display: block; font-size: 13px; }
.notice .nb p { font-size: 12px; color: var(--n500); line-height: 1.5; margin-top: 2px; }
.notice .nb small { font-size: 11px; color: var(--n500); }
.notice.unread { background: var(--mint); margin: 0 -14px; padding: 13px 14px; border-radius: var(--r8); border-bottom: none; }

.pricelist-filters { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.pricelist-filters::-webkit-scrollbar { display: none; }

@media (min-width: 768px) {
  .kpi-grid { grid-template-columns: repeat(4,1fr); }
  .aging { grid-template-columns: repeat(4,1fr); }
  .dtable thead { display: table-header-group; }
  .dtable thead th { text-align: left; font-size: 11.5px; color: var(--n500); font-weight: 500; padding: 11px 14px; border-bottom: 1px solid var(--n100); white-space: nowrap; }
  .dtable tbody tr { display: table-row; padding: 0; }
  .dtable td { display: table-cell; padding: 12px 14px; border-bottom: 1px solid var(--n100); vertical-align: middle; }
  .dtable td::before { content: none; }
  .dtable td.num { text-align: right; }
  .dtable thead th.num { text-align: right; }
  .dtable td.main { font-size: 13px; }
  .dtable .rowact { white-space: nowrap; }
}
@media (min-width: 1025px) {
  .kpi .val { font-size: 23px; }
  .terr-map { height: 320px; }
  .chart-col { height: 210px; }
}

/* ==================================================================
   ZALO MINIAPP  —  khung 375, nav Zalo, bottom nav
   ================================================================== */
body[data-app="mini"] { background: #D8E1EE; }
body[data-app="mini"] #site-header, body[data-app="mini"] #site-footer, body[data-app="mini"] .m-tabbar { display: none !important; }
.mini-frame { width: 375px; margin: 0 auto; background: var(--bg); min-height: 100vh; position: relative; padding-bottom: 62px; }
.zalo-status { background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: space-between; padding: 7px 14px 3px; font-size: 12.5px; font-weight: 700; }
.zalo-nav { background: var(--primary); color: #fff; display: flex; align-items: center; gap: 10px; padding: 6px 12px 12px; position: sticky; top: 0; z-index: 30; }
.zalo-nav .back { font-size: 20px; line-height: 1; }
.zalo-nav .ttl { font-weight: 700; font-size: 16px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zalo-nav .zbtns { display: flex; align-items: center; gap: 2px; background: rgba(255,255,255,.2); border-radius: var(--pill); padding: 3px 4px; font-size: 13px; }
.zalo-nav .zbtns span { width: 24px; text-align: center; }
.mini-body { padding: 12px; display: flex; flex-direction: column; gap: 12px; }
.mini-card { background: #fff; border-radius: var(--r12); padding: 14px; }
.mini-nav { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 375px; background: #fff; border-top: 1px solid var(--n100); display: grid; grid-template-columns: repeat(4,1fr); padding: 7px 0 9px; z-index: 40; }
.mini-nav a { text-align: center; font-size: 10.5px; color: var(--n500); }
.mini-nav a .em { display: block; font-size: 19px; line-height: 1.15; }
.mini-nav a.on { color: var(--primary); font-weight: 700; }
.mini-hero { background: var(--primary); color: #fff; padding: 0 14px 16px; }
.mini-quick { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px 6px; }
.mini-quick a { text-align: center; font-size: 10.5px; color: var(--n700); line-height: 1.3; }
.mini-quick a .em { display: flex; width: 46px; height: 46px; margin: 0 auto 5px; border-radius: 14px; background: var(--mint); align-items: center; justify-content: center; font-size: 21px; }
.mini-sticky { position: fixed; bottom: 62px; left: 50%; transform: translateX(-50%); width: 375px; background: #fff; border-top: 1px solid var(--n100); display: flex; gap: 8px; padding: 10px 12px; z-index: 39; }
.mini-list { display: flex; flex-direction: column; }
.mini-row { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--n100); }
.mini-row:last-child { border-bottom: none; }
.mini-thumb { width: 56px; height: 56px; border-radius: var(--r8); background: var(--n100); display: flex; align-items: center; justify-content: center; font-size: 22px; flex: none; }
.mini-qr { width: 128px; height: 128px; border-radius: var(--r8); background: #fff; display: flex; align-items: center; justify-content: center; font-size: 58px; margin: 0 auto; }
.mem-card { border-radius: 16px; padding: 16px; color: #fff; background: linear-gradient(125deg, var(--primary-deep), var(--primary) 55%, #3A466E); }

/* Dòng hàng trong giỏ sỉ: mobile xếp dọc để tên sản phẩm dài không bị bóp */
body[data-page="b2b-dat-hang"] .cart-line,
body[data-page="b2b-thanh-toan"] .cart-line {
  display: grid; grid-template-columns: 56px 1fr; gap: 10px 11px; align-items: start; padding: 14px 0;
}
body[data-page="b2b-dat-hang"] .cart-thumb,
body[data-page="b2b-thanh-toan"] .cart-thumb { width: 56px; height: 56px; font-size: 26px; }
body[data-page="b2b-dat-hang"] .cart-price,
body[data-page="b2b-thanh-toan"] .cart-price {
  grid-column: 1 / -1; text-align: left; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
  border-top: 1px dashed var(--n100); padding-top: 9px;
}
body[data-page="b2b-dat-hang"] .cart-price .trash,
body[data-page="b2b-thanh-toan"] .cart-price .trash { margin-left: auto; }
body[data-page="b2b-dat-hang"] .cart-info .name,
body[data-page="b2b-thanh-toan"] .cart-info .name { display: block; line-height: 1.45; }

@media (min-width: 768px) {
  body[data-page="b2b-dat-hang"] .cart-line,
  body[data-page="b2b-thanh-toan"] .cart-line { grid-template-columns: 64px 1fr auto; align-items: center; }
  body[data-page="b2b-dat-hang"] .cart-price,
  body[data-page="b2b-thanh-toan"] .cart-price {
    grid-column: auto; flex-direction: column; align-items: flex-end; gap: 3px; border-top: none; padding-top: 0;
  }
  body[data-page="b2b-dat-hang"] .cart-price .trash,
  body[data-page="b2b-thanh-toan"] .cart-price .trash { margin-left: 0; }
  body[data-page="b2b-dat-hang"] .cart-thumb,
  body[data-page="b2b-thanh-toan"] .cart-thumb { width: 64px; height: 64px; font-size: 30px; }
}
.mini-card ul { list-style: disc; padding-left: 18px; }
.mini-card ul li { margin-bottom: 2px; }
body[data-app="mini"] .spec-table td:first-child { width: 56%; }
.tier-grid { grid-template-columns: 1fr; }
@media (min-width: 768px) { .tier-grid { grid-template-columns: repeat(3, 1fr); align-items: start; } }

/* ==================================================================
   PHÁP LÝ · CSKH · TRẠNG THÁI HỆ THỐNG
   ================================================================== */
.legal-layout { display: grid; grid-template-columns: 1fr; gap: 16px; align-items: start; margin-top: 16px; }
.legal-toc { background: #fff; border-radius: var(--r12); padding: 14px; }
.legal-toc b { display: block; font-size: 13px; margin-bottom: 8px; }
.legal-toc a { display: block; font-size: 12.5px; color: var(--n700); padding: 7px 0; border-bottom: 1px solid var(--n100); }
.legal-toc a:last-child { border-bottom: none; }
.legal-toc a.on { color: var(--primary); font-weight: 700; }
.legal-body { background: #fff; border-radius: var(--r12); padding: 18px; }
.legal-body h2 { font-size: 18px; margin: 22px 0 8px; }
.legal-body h2:first-child { margin-top: 0; }
.legal-body h3 { font-size: 14.5px; margin: 16px 0 6px; }
.legal-body p, .legal-body li { font-size: 13.5px; line-height: 1.75; color: var(--n700); }
.legal-body ul, .legal-body ol { padding-left: 20px; margin: 8px 0; list-style: disc; }
.legal-body ol { list-style: decimal; }
.legal-body li { margin-bottom: 5px; }
.legal-meta { background: var(--bg); border-radius: var(--r8); padding: 12px 14px; font-size: 12px; color: var(--n500); line-height: 1.65; margin-bottom: 16px; }

/* Hàng bật/tắt quyền dữ liệu */
.consent-row { display: flex; gap: 12px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--n100); }
.consent-row:last-child { border-bottom: none; }
.consent-row .ct { flex: 1; min-width: 0; }
.consent-row .ct b { display: block; font-size: 13.5px; margin-bottom: 3px; }
.consent-row .ct p { font-size: 12px; color: var(--n500); line-height: 1.6; }
.consent-row .req { font-size: 11px; color: var(--n500); margin-top: 4px; display: inline-block; }
.switch { width: 46px; height: 26px; border-radius: 999px; background: var(--n300); position: relative; flex: none; }
.switch i { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; }
.switch.on { background: var(--primary); }
.switch.on i { left: 23px; }
.switch.lock { background: var(--n100); }
.switch.lock i { background: var(--n300); left: 23px; }

.data-card { display: flex; gap: 12px; align-items: center; padding: 13px 0; border-bottom: 1px solid var(--n100); }
.data-card:last-child { border-bottom: none; }
.data-card .ic { width: 38px; height: 38px; border-radius: var(--r8); background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 17px; flex: none; }
.data-card .dt { flex: 1; min-width: 0; }
.data-card .dt b { display: block; font-size: 13px; }
.data-card .dt small { color: var(--n500); font-size: 11.5px; }

/* Đánh giá */
.star-pick { display: flex; gap: 8px; font-size: 34px; color: var(--gold); }
.star-pick .off { color: var(--n300); }
.upload-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.upload-grid .cell { aspect-ratio: 1; border-radius: 10px; background: var(--n100); display: flex; align-items: center; justify-content: center; font-size: 22px; }
.upload-grid .add { background: none; border: 2px dashed var(--n300); color: var(--n500); }

/* Lịch sử điểm */
.point-row { display: flex; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--n100); }
.point-row:last-child { border-bottom: none; }
.point-row .ic { width: 36px; height: 36px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 15px; flex: none; background: var(--mint); }
.point-row .pi { flex: 1; min-width: 0; }
.point-row .pi b { display: block; font-size: 13px; }
.point-row .pi small { color: var(--n500); font-size: 11.5px; }
.point-row .amt { font-weight: 700; font-size: 14px; }
.point-row .amt.plus { color: var(--primary); }
.point-row .amt.minus { color: var(--sale); }

/* Trợ giúp */
.help-hero { background: linear-gradient(120deg, var(--primary-deep), var(--primary)); border-radius: var(--r12); padding: 24px 18px; text-align: center; color: #fff; }
.help-hero h1 { font-size: 22px; margin-bottom: 6px; }
.help-hero p { font-size: 13px; opacity: .9; margin-bottom: 14px; }
.help-search { background: #fff; border-radius: 999px; display: flex; align-items: center; gap: 10px; padding: 11px 16px; max-width: 560px; margin: 0 auto; }
.help-search span { color: var(--n500); font-size: 13.5px; }
.help-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.help-tile { background: #fff; border-radius: var(--r12); padding: 16px; text-align: center; }
.help-tile .em { font-size: 26px; display: block; margin-bottom: 6px; }
.help-tile b { font-size: 13px; display: block; }
.help-tile small { color: var(--n500); font-size: 11px; }

/* Trạng thái hệ thống */
.state-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.state-card { background: #fff; border-radius: var(--r12); overflow: hidden; }
.state-card .sh { background: var(--bg); padding: 10px 14px; font-size: 12px; font-weight: 700; color: var(--n700); display: flex; gap: 8px; align-items: center; }
.state-card .sb { padding: 30px 18px; text-align: center; }
.state-card .sb .em { font-size: 44px; display: block; margin-bottom: 10px; }
.state-card .sb b { font-size: 15.5px; display: block; margin-bottom: 5px; }
.state-card .sb p { font-size: 12.5px; color: var(--n500); line-height: 1.6; max-width: 340px; margin: 0 auto 14px; }
.state-note { padding: 0 14px 14px; font-size: 11.5px; color: var(--n500); line-height: 1.6; }
.state-note b { color: var(--n700); }

@media (min-width: 768px) {
  .help-grid { grid-template-columns: repeat(4, 1fr); }
  .upload-grid { grid-template-columns: repeat(6, 1fr); }
  .state-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1025px) {
  .legal-layout { grid-template-columns: 260px 1fr; }
  .legal-toc { position: sticky; top: 16px; }
  .legal-body { padding: 28px 32px; }
}
.moit-badge { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.1); border-radius: 6px; padding: 6px 11px; color: #fff; }
.moit-badge .mb-ic { width: 20px; height: 20px; border-radius: 50%; background: var(--sale); display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; flex: none; }
.moit-badge .mb-tx { font-size: 8.5px; line-height: 1.25; letter-spacing: .3px; opacity: .95; }
.moit-badge .mb-tx b { font-size: 9.5px; }

.footer-bottom .container { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
@media (min-width: 768px) { .cmp-two { grid-template-columns: 1fr 1fr !important; } }

/* ============ GHI CHÚ FIGMA 21/08/2026 ============ */
/* #3 — logo phương thức thanh toán (placeholder màu thương hiệu, chờ SVG chính thức) */
.pay-badges .pl { display: inline-flex; align-items: center; gap: 3px; height: 24px; padding: 0 9px; border-radius: 5px; font-size: 11px; font-weight: 800; letter-spacing: .2px; background: #fff; }
.pl-visa { color: #1A1F71; font-style: italic; }
.pl-mc { gap: 0; padding: 0 10px; }
.pl-mc .mc-a, .pl-mc .mc-b { width: 13px; height: 13px; border-radius: 50%; display: block; }
.pl-mc .mc-a { background: #EB001B; }
.pl-mc .mc-b { background: #F79E1B; margin-left: -5px; opacity: .92; }
.pl-vietqr { color: #0F1E4E; } .pl-vietqr b { color: #ED1B2F; margin-left: 1px; }
.pl-momo { background: #A50064; color: #fff; } .pl-momo i { font-style: normal; background: #fff; color: #A50064; border-radius: 50%; width: 14px; height: 14px; display: inline-flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 900; }
.pl-zalopay { color: #0068FF; } .pl-zalopay b { color: #00B14F; }
.pl-vnpay { color: #005BAA; } .pl-vnpay b { color: #ED1C24; }
.pl-kredivo { color: #0A2E5C; text-transform: lowercase; font-weight: 900; }
.pl-cod { color: var(--n700); }
.pl-ghn { background: #F96E2A; color: #fff; }
.pl-ghtk { background: #00904A; color: #fff; }

/* #4 — badge kiểu Shopee trên product card (badge engine từ ERP) */
.p-badges { display: flex; flex-wrap: nowrap; gap: 4px; margin: 2px 0; min-height: 18px; overflow: hidden; }  /* #15: luôn 1 dòng để các card cao bằng nhau */
.p-badges b { font-size: 10px; font-weight: 700; line-height: 1; padding: 3px 6px; border-radius: 3px; white-space: nowrap; flex: none; }
.pb-mall { background: var(--primary); color: #fff; }
.pb-fs { background: var(--skyl, #E7EDF6); color: #414A70; border: 1px solid #C9D4E6; }
.pb-fav { background: #F8ECEC; color: var(--cta, #D61518); border: 1px solid #EFC7C7; }
.pb-flash { background: #FF6B35; color: #fff; }  /* ngoại lệ #12: Flash Sale giữ bảng màu cam */
/* #2 — label card = tên danh mục */
.p-cate { font-size: 11px; font-weight: 600; color: var(--primary); text-transform: uppercase; letter-spacing: .4px; }

/* #8 — voucher breakdown trong checkout */
.vc-line { display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 5px 0; }
.vc-line .vc-code { background: var(--mint, #E4EBF5); color: var(--pdark, #131D3B); border: 1px dashed var(--primary); border-radius: 4px; padding: 2px 7px; font-weight: 700; font-size: 11px; white-space: nowrap; }
.vc-line .vc-lbl { color: var(--n700); flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vc-line .vc-amt { font-weight: 700; color: var(--pdark, #131D3B); white-space: nowrap; }
.vc-line .vc-x { border: 0; background: none; color: var(--n500); cursor: pointer; font-size: 13px; padding: 0 2px; }

/* #9 — chọn nhanh địa chỉ (địa giới mới 34 tỉnh, 2 cấp) */
.addr-quick { display: flex; align-items: center; gap: 10px; border: 1.5px solid var(--primary); background: var(--mint, #E4EBF5); border-radius: var(--r8); padding: 11px 13px; cursor: pointer; margin-bottom: 12px; }
.addr-quick .aq-ic { font-size: 18px; }
.addr-quick .aq-tx { flex: 1; min-width: 0; font-size: 14px; }
.addr-quick .aq-tx b { display: block; color: var(--n900); }
.addr-quick .aq-tx small { color: var(--n500); font-size: 12px; }
.addr-quick .aq-ar { color: var(--primary); font-weight: 700; }
.field select, .field input { width: 100%; min-width: 0; max-width: 100%; }

/* ============ GHI CHÚ FIGMA #12–#24 (23/08/2026) ============ */
/* #19 — trạng thái nhập voucher đúng / sai */
.promo-input.ok input { border-color: var(--primary); background: var(--mint); }
.promo-input.bad input { border-color: var(--cta); background: #FDECEC; }
.promo-msg { display: flex; align-items: flex-start; gap: 6px; font-size: 12px; line-height: 1.45; margin: -6px 0 12px; }
.promo-msg.ok { color: var(--pdark, #131D3B); }
.promo-msg.bad { color: var(--cta); }
.promo-msg b { font-weight: 700; }
.promo-state { border: 1px dashed var(--n300); border-radius: var(--r8); padding: 12px; margin: 12px 0; }
.promo-state > b { display: block; font-size: 11px; letter-spacing: .4px; color: var(--n500); text-transform: uppercase; margin-bottom: 8px; }

/* #20 — làm nổi bật khối voucher đã áp trong tóm tắt đơn */
.vc-hl { background: var(--mint); border: 1px solid var(--primary); border-radius: var(--r8); padding: 10px 11px; margin: 8px 0; }
.vc-hl .vc-hl-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.vc-hl .vc-hl-top b { font-size: 13px; color: var(--n900); }
.vc-hl .vc-save { background: var(--cta); color: #fff; font-size: 12px; font-weight: 800; border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.vc-hl .sum-row { font-size: 12.5px; padding: 3px 0; }
.vc-hl .sum-row b { font-weight: 700; }

/* #22 — field tự điền từ Zalo/OTP + nút đổi */
.field-locked { display: flex; align-items: center; gap: 8px; border: 1px solid var(--n300); border-radius: var(--r8); height: 44px; padding: 0 8px 0 12px; background: var(--n100); }
.field-locked .fl-val { flex: 1; min-width: 0; font-size: 14px; color: var(--n900); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field-locked .fl-src { font-size: 11px; color: var(--n500); white-space: nowrap; }
.field-locked .fl-btn { border: 1px solid var(--primary); color: var(--primary); background: #fff; font-size: 12px; font-weight: 700; border-radius: 6px; padding: 5px 10px; white-space: nowrap; }

/* #23 — đặt hộ người thân */
.gift-order { border: 1px dashed var(--primary); border-radius: var(--r8); padding: 11px 12px; margin-top: 12px; background: var(--mint); }
.gift-order > label { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; color: var(--n900); }
.gift-order .go-fields { margin-top: 11px; display: grid; grid-template-columns: minmax(0,1fr); gap: 10px; }
@media (min-width: 768px) { .gift-order .go-fields { grid-template-columns: minmax(0,1fr) minmax(0,1fr); } }

/* #24 — dropdown xem nhanh sản phẩm trong đơn */
.od-toggle { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 600; color: var(--primary); border: 1px solid var(--n300); border-radius: 999px; padding: 4px 11px; background: #fff; }
.od-peek { margin-top: 10px; border-top: 1px dashed var(--n300); padding-top: 10px; display: grid; gap: 8px; }
.od-line { display: flex; align-items: center; gap: 9px; font-size: 12.5px; }
.od-line .od-th { width: 34px; height: 34px; border-radius: 6px; background: var(--mint); display: flex; align-items: center; justify-content: center; font-size: 17px; flex: none; }
.od-line .od-nm { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--n700); }
.od-line .od-qt { color: var(--n500); white-space: nowrap; }
.od-more { font-size: 12px; color: var(--n500); }

/* #9 (bổ sung) — bottom sheet chọn địa chỉ */
.sheet-demo { border: 1px solid var(--n300); border-radius: var(--r12); overflow: hidden; background: #fff; max-width: 390px; }
.sheet-demo .sh-head { padding: 12px 14px; border-bottom: 1px solid var(--n100); display: flex; align-items: center; justify-content: space-between; }
.sheet-demo .sh-head b { font-size: 15px; }
.sheet-demo .sh-search { margin: 12px 14px; display: flex; align-items: center; gap: 8px; border: 1px solid var(--n300); border-radius: var(--r8); height: 40px; padding: 0 12px; color: var(--n500); font-size: 13.5px; }
.sheet-demo .sh-crumb { padding: 0 14px 8px; font-size: 12px; color: var(--n500); }
.sheet-demo .sh-crumb b { color: var(--primary); }
.sheet-demo .sh-list { border-top: 1px solid var(--n100); }
.sheet-demo .sh-item { padding: 11px 14px; border-bottom: 1px solid var(--n100); font-size: 13.5px; display: flex; justify-content: space-between; gap: 8px; }
.sheet-demo .sh-item.sel { color: var(--primary); font-weight: 700; background: var(--mint); }
.sheet-demo .sh-item small { color: var(--n500); font-weight: 400; }

/* #17 — combo giá: nhấn/hover thì giá phía trên nháy cập nhật */
.price-live { position: relative; }
.price-live .pl-tag { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; color: var(--cta); background: #FDECEC; border-radius: 999px; padding: 3px 9px; margin-left: 8px; vertical-align: 3px; }

/* #18 — gợi ý size từ hồ sơ bé */
.size-hint { display: flex; align-items: flex-start; gap: 8px; background: var(--mint); border-left: 3px solid var(--primary); border-radius: 0 var(--r8) var(--r8) 0; padding: 9px 12px; font-size: 12.5px; color: var(--n700); margin: 4px 0 10px; }
.size-hint b { color: var(--n900); }
.chip.suggested { border-color: var(--primary); box-shadow: 0 0 0 2px var(--mint); position: relative; }
.chip.suggested::after { content: "Gợi ý"; position: absolute; top: -9px; right: -6px; background: var(--primary); color: #fff; font-size: 9px; font-weight: 700; border-radius: 999px; padding: 1px 6px; }

/* marker cấu hình admin dùng chung */
.admin-hint { display: inline-flex; align-items: center; gap: 4px; background: var(--mint); color: var(--pdark, #131D3B); font-size: 10px; font-weight: 700; letter-spacing: .4px; border-radius: 999px; padding: 3px 8px; vertical-align: 2px; }
.order-row:has(.od-peek) { align-items: flex-start; }
