/* =========================================================
   SHOP DUY THIÊN – giao diện khách xem
   ========================================================= */
:root {
  --red: #c80900;
  --red-bright: #f20c1b;
  --red-dark: #9f0406;
  --gold: #fcbc2c;
  --text: #1d1d1d;
  --muted: #666;
  --line: #ececec;
  --pink: #fbe4e4;
  --zalo: #0068ff;
  --radius: 15px;
  --shadow: 0 0 4px rgba(0, 0, 0, .25);
  --container: 1200px;
  --header-h: 72px;
  --f-body: 'Roboto', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --f-nav: 'Chakra Petch', 'Roboto', sans-serif;
  --f-display: 'UTM Akashi', 'Saira', 'Chakra Petch', 'Roboto', sans-serif; /* tiêu đề: font UTM như web cũ */
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 15px/1.55 var(--f-body); color: var(--text); background: #fff; overflow-x: hidden; }
img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--red); }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5em; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
.center { text-align: center; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 999; background: #fff; padding: 8px 12px; }
.skip-link:focus { left: 8px; }
.icon { flex: none; vertical-align: middle; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- nút ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 42px; padding: 0 18px; border-radius: 6px; border: 1px solid transparent; cursor: pointer; font-weight: 500; white-space: nowrap; transition: .2s; }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); color: #fff; }
.btn-outline { background: #fff; border-color: #f0b9b9; color: var(--red); }
.btn-outline:hover { background: var(--pink); }
/* Nút đỏ có khung vát góc giống web cũ */
.btn-frame {
  position: relative; display: inline-flex; align-items: center; justify-content: center; min-width: 150px; height: 40px; padding: 0 26px;
  color: #fff; font-weight: 700; font-size: 14px; background: var(--red-bright); border-radius: 4px;
  clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px);
  box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .18); transition: .2s;
}
.btn-frame::after { content: ''; position: absolute; inset: 3px; border: 1px solid rgba(255, 255, 255, .45); clip-path: inherit; pointer-events: none; }
.btn-frame:hover { background: var(--red-dark); color: #fff; transform: translateY(-1px); }
.zalo-badge { display: inline-flex; align-items: center; justify-content: center; height: 26px; padding: 0 6px; border-radius: 7px; background: #fff; color: var(--zalo); font: 700 11px/1 var(--f-body); letter-spacing: -.2px; }
.zalo-badge.sm { height: 18px; padding: 0 4px; font-size: 9px; border-radius: 5px; background: var(--zalo); color: #fff; }
.zalo-badge.light { background: #fff; color: var(--zalo); }
.icon-btn { display: none; align-items: center; justify-content: center; width: 42px; height: 42px; padding: 0; border: 0; background: none; cursor: pointer; color: var(--text); }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 100; background: #fff; box-shadow: 0 1px 0 var(--line); transition: box-shadow .2s; }
.site-header.scrolled { box-shadow: 0 4px 18px rgba(0, 0, 0, .08); }
.header-inner { display: flex; align-items: center; gap: 24px; height: var(--header-h); }
.logo { flex: none; display: flex; align-items: center; }
.logo img { height: 56px; width: auto; }
.logo-text { font: 800 22px/1 var(--f-display); color: var(--red); }
.main-nav { margin-left: auto; }
.nav-head, .nav-contact, .sub-toggle { display: none; }
.menu { display: flex; align-items: center; gap: 6px; list-style: none; margin: 0; padding: 0; }
.menu > li { position: relative; }
.menu a { display: flex; align-items: center; gap: 4px; padding: 10px 16px; font: 600 15px/1.2 var(--f-nav); text-transform: uppercase; color: var(--text); transition: color .2s; }
.menu a.active, .menu li:hover > a { color: var(--gold); }
.menu .caret { opacity: .7; }
.menu .sub { position: absolute; top: 100%; left: 0; min-width: 230px; list-style: none; margin: 0; padding: 8px 0; background: #fff; border-radius: 10px; box-shadow: 0 12px 30px rgba(0, 0, 0, .14); opacity: 0; visibility: hidden; transform: translateY(8px); transition: .2s; }
.menu .sub .sub { top: -8px; left: 100%; }
.menu li:hover > .sub, .menu li:focus-within > .sub { opacity: 1; visibility: visible; transform: none; }
.menu .sub a { justify-content: space-between; padding: 10px 18px; font-size: 14px; text-transform: none; font-family: var(--f-body); font-weight: 500; }
.menu .sub a:hover { background: var(--pink); color: var(--red); }
.search-toggle { display: flex; }
/* nút Zalo đầu trang (web chỉ liên hệ qua Zalo, không có nút gọi) */
.header-zalo {
  flex: none; display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 20px; border-radius: 6px;
  background: var(--zalo); color: #fff; font-size: 14px; box-shadow: 0 0 0 3px #fff, 0 0 0 4px rgba(0, 104, 255, .45);
  clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px);
}
.header-zalo b { font-weight: 700; }
.header-zalo:hover { background: #0054cc; color: #fff; }
.search-bar { position: absolute; left: 0; right: 0; top: 100%; background: #fff; box-shadow: 0 10px 20px rgba(0, 0, 0, .08); padding: 12px 0; display: none; }
.search-bar.open { display: block; }
.search-inner { display: flex; gap: 8px; }
.search-inner input { flex: 1; min-width: 0; height: 44px; padding: 0 14px; border: 1px solid #ddd; border-radius: 6px; }

/* ---------- breadcrumb ---------- */
.breadcrumb-bar { background: var(--pink); font-size: 14px; }
.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; list-style: none; margin: 0; padding: 10px 0; }
.breadcrumb li { display: flex; align-items: center; gap: 10px; margin-right: 10px; color: #666; }
.breadcrumb li.active span { color: var(--red); font-weight: 500; }

/* ---------- tiêu đề ---------- */
.page { padding-top: 8px; padding-bottom: 50px; }
.page-title, .title-dark {
  font: 400 clamp(28px, 4.4vw, 50px)/1.22 var(--f-display); text-transform: uppercase; text-align: center;
  color: #242424; margin: 34px 0 26px;
}
.title-dark.small { font-size: clamp(22px, 3vw, 30px); text-align: left; }
.title-gold {
  font: 400 clamp(30px, 5vw, 50px)/1.22 var(--f-display); text-transform: uppercase; text-align: center;
  margin: 0 0 34px; background: linear-gradient(to bottom, #fff3b0, #f2d36b 55%, #caa43b);
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 1px #e0c15a; filter: drop-shadow(0 3px 2px rgba(80, 0, 0, .55));
}

/* ---------- trang chủ ---------- */
.hero { position: relative; overflow: hidden; background: #1a0000; }
.hero-track { display: flex; transition: transform .6s ease; }
.hero-slide { flex: 0 0 100%; }
.hero .banner-media { width: 100%; }
.hero-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .35); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.hero-nav.prev { left: 12px; } .hero-nav.next { right: 12px; }
.hero-dots { position: absolute; bottom: 12px; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; }
.hero-dots button { width: 10px; height: 10px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .5); cursor: pointer; padding: 0; }
.hero-dots button.active { background: #fff; width: 26px; border-radius: 6px; }
.home-shop { background: #fff url(../img/bg-home.webp) center / 100% 100% no-repeat; padding: 110px 0 120px; }
.home-banner { margin-bottom: 16px; border-radius: 16px; overflow: hidden; box-shadow: 0 0 0 3px #fff, 0 10px 30px rgba(0, 0, 0, .25); }
.home-banner .banner-media { width: 100%; }
.cat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.cat-card { background: #fff; border-radius: var(--radius); padding: 8px 8px 22px; text-align: center; box-shadow: 0 6px 18px rgba(0, 0, 0, .18); }
.cat-pic { display: block; overflow: hidden; border-radius: 10px; }
.cat-pic img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; transition: transform .4s; }
.cat-card:hover .cat-pic img { transform: scale(1.04); }
.cat-card h3 { margin: 16px 8px 4px; font: 400 22px/1.2 var(--f-display); letter-spacing: .3px; text-transform: uppercase; }
.cat-card h3 a { color: #1b1b1b; transition: color .2s; }
.cat-card h3 a:hover { color: var(--red); }
.cat-count { margin: 0 0 14px; color: var(--muted); font-size: 14px; font-weight: 400; }
.cat-count b { color: var(--red); font-weight: 700; }
.home-latest { padding: 10px 0 60px; }
.home-latest .center { margin-top: 30px; }

/* ---------- danh sách acc ---------- */
.filter-box { display: grid; grid-template-columns: 1fr 1fr 1.4fr auto; gap: 14px; align-items: end; padding: 16px; background: #fff; border-radius: 10px; box-shadow: 0 2px 14px rgba(0, 0, 0, .08); margin-bottom: 14px; }
.fg label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.fg select, .fg input { width: 100%; height: 42px; padding: 0 12px; border: 1px solid #e3e3e3; border-radius: 6px; background: #fff; }
.fg select { appearance: none; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") right 12px center no-repeat; padding-right: 32px; }
.fg-actions { display: flex; gap: 8px; }
.result-count { color: var(--muted); font-size: 14px; margin: 0 0 14px; min-height: 1em; }
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.product-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 10px 10px 18px; text-align: center; transition: transform .2s, box-shadow .2s; min-width: 0; }
.product-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(0, 0, 0, .15); }
.pc-pic { position: relative; aspect-ratio: 400 / 720; overflow: hidden; border-radius: 8px; background: #14101e; }
.pc-pic img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.pc-noimg { display: flex; height: 100%; align-items: center; justify-content: center; color: #777; }
.pc-name { font-size: 15px; font-weight: 700; margin: 14px 0 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--text); }
.pc-price { color: var(--red); font-weight: 500; }
.pc-price del { color: #999; font-size: 13px; margin-left: 4px; font-weight: 400; }
.badge-sold, .badge-hot { position: absolute; top: 10px; left: 10px; padding: 3px 10px; border-radius: 4px; font: 700 12px/1.4 var(--f-body); color: #fff; text-transform: uppercase; }
.badge-sold { background: rgba(0, 0, 0, .75); }
.badge-sold.big { top: 14px; left: 14px; font-size: 16px; padding: 6px 14px; }
.badge-hot { background: var(--red-bright); }
.product-card.is-sold .pc-pic img { filter: grayscale(.8) brightness(.8); }
.pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 34px; }
.pagination a, .pagination span { min-width: 40px; height: 40px; padding: 0 10px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; border: 1px solid #e5e5e5; background: #fff; font-weight: 500; }
.pagination a:hover { border-color: var(--red); color: var(--red); }
.pagination .current { background: var(--red); border-color: var(--red); color: #fff; }
.pagination .dots { border: 0; background: none; }
.empty { text-align: center; padding: 40px 16px; background: #fafafa; border-radius: 10px; color: var(--muted); }
.empty a { color: var(--red); }

/* ---------- chi tiết acc ---------- */
.pd-top { display: grid; grid-template-columns: minmax(0, 400px) minmax(0, 1fr); gap: 30px; align-items: start; margin-top: 30px; }
.pd-main { position: relative; display: block; max-height: 660px; overflow: hidden; border-radius: 10px; background: #14101e; box-shadow: var(--shadow); cursor: zoom-in; }
.pd-main img { width: 100%; }
.pd-main::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; background: linear-gradient(transparent, rgba(0, 0, 0, .75)); pointer-events: none; }
.pd-zoom { position: absolute; z-index: 1; left: 50%; bottom: 16px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 30px; background: rgba(255, 255, 255, .92); color: var(--text); font-size: 14px; font-weight: 500; white-space: nowrap; }
.pd-noimg { display: flex; align-items: center; justify-content: center; aspect-ratio: 1 / 1.4; color: #888; cursor: default; }
.pd-thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; }
.pd-thumbs a { flex: none; width: 72px; height: 72px; border-radius: 6px; overflow: hidden; border: 2px solid transparent; }
.pd-thumbs a:hover { border-color: var(--red); }
.pd-thumbs img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.pd-info { padding: 24px; border-radius: 10px; background: #fff; box-shadow: 0 2px 16px rgba(0, 0, 0, .08); position: sticky; top: calc(var(--header-h) + 16px); }
.pd-title { color: var(--red); font-size: clamp(22px, 2.6vw, 30px); font-weight: 700; margin-bottom: 8px; word-break: break-word; }
.pd-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; list-style: none; margin: 0 0 14px; padding: 0; font-size: 14px; color: var(--muted); }
.pd-meta b { color: var(--red); }
.pd-meta a { color: var(--red); font-weight: 500; }
.pd-meta .sep { color: #ccc; }
.pd-price { font-size: 26px; color: var(--red); font-weight: 500; margin-bottom: 6px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; }
.pd-price del { font-size: 16px; color: #999; }
.pd-discount { font-size: 13px; background: var(--red-bright); color: #fff; padding: 2px 8px; border-radius: 4px; }
.pd-status { font-size: 14px; margin: 0 0 18px; }
.pd-status.is-ok { color: #138a36; }
.pd-status.is-sold { color: #b45309; background: #fff7e6; padding: 8px 12px; border-radius: 6px; }
.pd-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; } /* trái đỏ: số Zalo, phải xanh: Liên hệ Zalo (cả 2 mở Zalo) */
.btn-pd { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; padding: 8px 14px; border-radius: 6px; color: #fff; font-weight: 700; font-size: 14px; text-transform: uppercase; line-height: 1.3; text-align: left; transition: .2s; }
.btn-pd:hover { color: #fff; filter: brightness(1.08); transform: translateY(-1px); }
.btn-pd-red { background: var(--red); }
.btn-pd-zalo { background: var(--zalo); }
.pd-hint { font-size: 13px; color: var(--muted); margin: 10px 0 0; }
.pd-hint .icon { margin: -2px 4px 0 0; }
.pd-share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; }
.pd-share > span { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); margin-right: 4px; }
.pd-share a, .pd-share button { height: 32px; padding: 0 10px; border-radius: 6px; display: inline-flex; align-items: center; gap: 6px; border: 0; cursor: pointer; font-size: 13px; font-weight: 600; }
.share-fb { background: #1877f2; color: #fff; }
.share-zalo { background: var(--zalo); color: #fff; }
.share-copy { background: #f1f1f1; }
.pd-share a:hover { color: #fff; filter: brightness(1.1); }
.pd-bottom { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 24px; margin-top: 36px; align-items: start; }
.pd-tabs, .pd-hot { background: #fff; border-radius: 10px; box-shadow: 0 2px 16px rgba(0, 0, 0, .08); padding: 18px 20px; }
.tab-head { display: flex; gap: 24px; border-bottom: 1px solid #f3c9c9; margin-bottom: 16px; }
.tab-head button { background: none; border: 0; padding: 8px 0 10px; font-weight: 500; font-size: 15px; text-transform: uppercase; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab-head button.active { color: var(--red); border-bottom-color: var(--red); }
.tab-body[hidden] { display: none; }
.pd-spec { width: 100%; border-collapse: collapse; margin-bottom: 14px; font-size: 14px; }
.pd-spec th, .pd-spec td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.pd-spec th { width: 140px; color: var(--muted); font-weight: 500; background: #fafafa; }
.pd-spec .red { color: var(--red); font-weight: 700; }
.pd-spec a { color: var(--red); }
.pd-full { display: block; margin-bottom: 12px; border-radius: 8px; overflow: hidden; cursor: zoom-in; }
.pd-full img { width: 100%; }
.pd-hot h3 { color: var(--red); font-size: 16px; text-transform: uppercase; margin-bottom: 12px; }
.pd-hot ul { list-style: none; margin: 0; padding: 0; max-height: 520px; overflow-y: auto; }
.pd-hot li + li { margin-top: 10px; }
.pd-hot a { display: flex; gap: 12px; align-items: center; }
.hot-pic { flex: none; width: 56px; height: 56px; border-radius: 6px; overflow: hidden; background: #14101e; }
.hot-pic img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.hot-info { display: flex; flex-direction: column; min-width: 0; font-size: 14px; }
.hot-info b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
.hot-info em { color: var(--red); font-style: normal; font-weight: 700; }
.related { margin-top: 20px; }
.rich { line-height: 1.7; }
.rich img { border-radius: 8px; margin: 10px 0; }
.rich a { color: var(--red); text-decoration: underline; }

/* ---------- lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 1000; background: rgba(0, 0, 0, .94); }
.lightbox[hidden] { display: none; }
.lb-scroll { position: absolute; inset: 0; overflow: auto; overscroll-behavior: contain; padding: 60px 0 30px; }
.lb-img { margin: 0 auto; max-width: min(100%, 980px); cursor: zoom-in; }
.lightbox.zoomed .lb-img { max-width: none; cursor: zoom-out; }
.lb-bar { position: absolute; top: 0; left: 0; right: 0; height: 54px; display: flex; align-items: center; justify-content: flex-end; gap: 6px; padding: 0 10px; background: linear-gradient(rgba(0, 0, 0, .7), transparent); color: #fff; }
.lb-count { margin-right: auto; padding-left: 8px; font-size: 14px; }
.lb-bar button, .lb-prev, .lb-next { width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.lb-prev, .lb-next { position: absolute; top: 50%; transform: translateY(-50%); }
.lb-prev { left: 10px; } .lb-next { right: 10px; }
.lightbox.single .lb-prev, .lightbox.single .lb-next { display: none; }
body.no-scroll { overflow: hidden; }

/* ---------- tin tức ---------- */
.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.post-card { border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); background: #fff; }
.post-pic { aspect-ratio: 16 / 9; background: var(--pink); overflow: hidden; }
.post-pic img { width: 100%; height: 100%; object-fit: cover; }
.post-body { padding: 14px 16px 18px; }
.post-body time { font-size: 13px; color: var(--muted); }
.post-body h2 { font-size: 17px; margin: 4px 0 6px; }
.post-body p { margin: 0; font-size: 14px; color: #444; }
.post-detail { max-width: 860px; }
.post-title { font-size: clamp(24px, 3vw, 34px); margin-top: 30px; }
.post-meta { color: var(--muted); font-size: 14px; }
.post-summary { font-weight: 500; font-size: 16px; }
.post-others { padding-left: 18px; }
.post-others li { margin-bottom: 6px; }
.post-others time { color: var(--muted); font-size: 13px; }

/* ---------- liên hệ ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.contact-form, .contact-info { background: #fff; border-radius: 10px; box-shadow: 0 2px 16px rgba(0, 0, 0, .08); padding: 22px; }
.field { display: block; margin-bottom: 12px; }
.field span { display: block; font-size: 14px; font-weight: 500; margin-bottom: 4px; }
.field input, .field textarea { width: 100%; padding: 10px 12px; border: 1px solid #ddd; border-radius: 6px; background: #fff; }
.field input:focus, .field textarea:focus { border-color: var(--red); outline: none; box-shadow: 0 0 0 3px rgba(200, 9, 0, .1); }
.field-error { display: block; color: var(--red); font-size: 13px; margin-top: 4px; }
.form-actions { display: flex; gap: 8px; }
.hp { position: absolute; left: -9999px; }
.alert { padding: 12px 14px; border-radius: 8px; margin-bottom: 14px; display: flex; gap: 8px; align-items: center; }
.alert.ok { background: #e8f7ee; color: #146c34; }
.alert.err { background: #fdecec; color: var(--red-dark); }
.contact-info h2 { font: 800 24px/1.2 var(--f-display); color: var(--red); }
.contact-info ul { list-style: none; padding: 0; margin: 0 0 18px; }
.contact-info li { display: flex; align-items: center; gap: 8px; padding: 9px 0; border-bottom: 1px dashed #eee; }
.contact-info li a { color: var(--red); }
.map { margin-top: 18px; border-radius: 8px; overflow: hidden; }
.map iframe { width: 100%; height: 300px; border: 0; display: block; }

/* ---------- 404 ---------- */
.notfound { padding: 40px 16px 60px; }
.nf-code { font: 800 90px/1 var(--f-display); color: var(--red); margin: 20px 0 0; }
.nf-search { display: flex; gap: 8px; max-width: 460px; margin: 20px auto; }
.nf-search input { flex: 1; min-width: 0; height: 42px; padding: 0 12px; border: 1px solid #ddd; border-radius: 6px; }

/* ---------- footer ---------- */
.site-footer { background: #8b0000 url(../img/bg-footer.webp) center / cover no-repeat; color: #fff; padding: 60px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.footer-name { font: 400 clamp(34px, 5.4vw, 65px)/1.2 var(--f-display); text-transform: uppercase; margin-bottom: 18px; }
.footer-info p { margin: 0 0 12px; font-size: 14px; font-weight: 700; }
.footer-info a:hover { color: var(--gold); }
.footer-social { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; font-size: 14px; }
.footer-social a { width: 40px; height: 40px; border-radius: 50%; background: #fff; color: var(--red); display: inline-flex; align-items: center; justify-content: center; transition: .2s; }
.footer-social a:hover { background: var(--gold); color: #fff; }
.social-zalo { font-size: 11px; font-weight: 700; }
.footer-card { background: #fff; border-radius: var(--radius); padding: 26px; display: grid; gap: 14px; }
.footer-card .banner-media { width: 100%; border-radius: 6px; }
.footer-bottom { margin-top: 36px; font-size: 13px; opacity: .92; }

/* ---------- nút liên hệ nổi ---------- */
.float-contact { position: fixed; right: 18px; bottom: 24px; z-index: 90; display: flex; flex-direction: column; gap: 12px; }
.float-contact a { width: 54px; height: 54px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; box-shadow: 0 6px 18px rgba(0, 0, 0, .25); }
.fc-zalo { background: var(--zalo); font: 700 13px/1 var(--f-body); position: relative; }
.fc-zalo::before { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid rgba(0, 104, 255, .45); animation: pulse 2s infinite; }
.fc-mess { background: linear-gradient(45deg, #0a7cff, #a033ff); }
.float-contact a:hover { color: #fff; transform: scale(1.06); }
@keyframes pulse { 0% { transform: scale(.9); opacity: 1; } 100% { transform: scale(1.35); opacity: 0; } }
.mobile-bar { display: none; }
.to-top { position: fixed; right: 24px; bottom: 170px; z-index: 89; width: 42px; height: 42px; border-radius: 50%; border: 0; background: #fff; color: var(--red); box-shadow: 0 4px 14px rgba(0, 0, 0, .2); cursor: pointer; display: flex; align-items: center; justify-content: center; opacity: 0; visibility: hidden; transition: .2s; }
.to-top.show { opacity: 1; visibility: visible; }
.toast { position: fixed; left: 50%; bottom: 90px; transform: translate(-50%, 20px); z-index: 1100; max-width: calc(100% - 32px); padding: 12px 18px; border-radius: 8px; background: #222; color: #fff; font-size: 14px; opacity: 0; visibility: hidden; transition: .25s; text-align: center; }
.toast.show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

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

/* =========================================================
   Máy tính bảng & điện thoại
   ========================================================= */
@media (max-width: 1100px) {
  .menu a { padding: 10px 10px; }
  .header-inner { gap: 14px; }
}

@media (max-width: 991px) {
  :root { --header-h: 64px; }
  .icon-btn { display: flex; }
  .header-inner { gap: 6px; }
  .logo { margin: 0 auto; }
  .logo img { height: 48px; }
  .header-zalo { display: none; }
  .main-nav { position: fixed; top: 0; left: 0; bottom: 0; z-index: 200; width: min(320px, 86vw); background: #fff; overflow-y: auto; transform: translateX(-100%); transition: transform .28s ease; margin: 0; box-shadow: 4px 0 30px rgba(0, 0, 0, .2); }
  body.nav-open .main-nav { transform: none; }
  body.nav-open { overflow: hidden; }
  .nav-overlay { position: fixed; inset: 0; z-index: 150; background: rgba(0, 0, 0, .45); }
  body.nav-open .nav-overlay { display: block !important; }
  .nav-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 8px 18px; background: var(--red); color: #fff; font: 800 17px/1 var(--f-display); }
  .nav-head .icon-btn { color: #fff; }
  .menu { display: block; padding: 8px 0; }
  .menu li { position: relative; border-bottom: 1px solid #f3f3f3; }
  .menu a { padding: 14px 18px; }
  .menu .caret { display: none; }
  .menu .sub { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border-radius: 0; padding: 0; display: none; background: #fafafa; }
  .menu li.open > .sub { display: block; }
  .menu .sub a { padding-left: 32px; }
  .menu .sub .sub a { padding-left: 46px; }
  .sub-toggle { display: flex; position: absolute; right: 4px; top: 4px; width: 42px; height: 42px; align-items: center; justify-content: center; border: 0; background: none; cursor: pointer; transition: transform .2s; }
  li.open > .sub-toggle { transform: rotate(180deg); }
  .nav-contact { display: block; list-style: none; margin: 10px 0 20px; padding: 0 18px; font-size: 14px; }
  .nav-contact li { display: flex; align-items: center; gap: 8px; padding: 8px 0; }
  .pd-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
  .pd-bottom { grid-template-columns: 1fr; }
  .product-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .filter-box { grid-template-columns: 1fr 1fr; }
  .fg-actions { grid-column: 1 / -1; }
  .fg-actions .btn { flex: 1; }
  .post-grid { grid-template-columns: repeat(2, 1fr); }
  .home-shop { padding: 70px 0 80px; }
}

@media (max-width: 767px) {
  body { padding-bottom: 58px; }
  .float-contact { display: none; }
  .mobile-bar { display: grid; grid-template-columns: 1fr 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 95; height: 58px; box-shadow: 0 -4px 16px rgba(0, 0, 0, .12); }
  .mobile-bar a { display: flex; align-items: center; justify-content: center; gap: 8px; color: #fff; font-weight: 700; font-size: 15px; }
  .mb-zalo-num { background: var(--red); } /* nút trái: số Zalo (trước là nút Gọi) */
  .mb-zalo { background: var(--zalo); }
  .to-top { right: 14px; bottom: 74px; }
  .toast { bottom: 76px; }
  .pd-top { grid-template-columns: 1fr; margin-top: 18px; }
  .pd-main { max-height: 520px; }
  .pd-info { position: static; padding: 18px; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .contact-grid { grid-template-columns: 1fr; }
  .post-grid { grid-template-columns: 1fr; }
  .home-shop { padding: 50px 0 60px; background-size: cover; }
  .title-gold { margin-bottom: 22px; }
  .page-title, .title-dark { margin: 24px 0 18px; }
}

@media (max-width: 575px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .product-card { padding: 6px 6px 12px; border-radius: 10px; }
  .pc-name { font-size: 13px; margin: 10px 0 4px; }
  .pc-price { font-size: 14px; }
  .cat-grid { gap: 10px; }
  .cat-card { padding: 6px 6px 14px; border-radius: 10px; }
  .cat-card h3 { font-size: 15px; margin-top: 10px; }
  .cat-count { font-size: 12px; margin-bottom: 10px; }
  .btn-frame { min-width: 0; width: 100%; max-width: 150px; height: 36px; font-size: 13px; padding: 0 12px; }
  .filter-box { grid-template-columns: 1fr; gap: 10px; padding: 12px; }
  .pd-actions { grid-template-columns: 1fr; }
  .tab-head { gap: 16px; }
  .pd-tabs, .pd-hot { padding: 14px; }
  .pd-spec th { width: 105px; }
  .footer-card { padding: 16px; }
}

/* ---------- trang tĩnh, chân trang thêm ---------- */
.footer-text { font-size: 14px; margin: 6px 0 4px; }
.footer-text p { font-weight: 400; }
.footer-text a { text-decoration: underline; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; }
.footer-bottom .counter b { font-weight: 700; }
.contact-intro { max-width: 860px; margin: -6px auto 22px; text-align: center; color: #444; }

/* iPhone: ô nhập chữ nhỏ hơn 16px sẽ bị phóng to khi bấm vào -> giữ 16px */
@supports (-webkit-touch-callout: none) {
  input, textarea, select { font-size: 16px !important; }
}
.pd-summary { margin: 0 0 12px; color: #333; font-size: 15px; }
.pd-summary p { margin: 0 0 6px; }
/* nội dung soạn bằng trình soạn thảo: bảng, trích dẫn, video */
.rich table { width: 100%; margin: 10px 0; border-collapse: collapse; }
.rich td, .rich th { padding: 6px 10px; border: 1px solid #ddd; vertical-align: top; }
.rich th { background: #f5f5f5; text-align: left; }
.rich blockquote { margin: 12px 0; padding: 8px 14px; border-left: 4px solid var(--red); background: #fff6f5; }
.rich hr { margin: 16px 0; border: 0; border-top: 1px solid #ddd; }
.rich iframe[src*="youtube"] { display: block; width: 100%; max-width: 760px; height: auto; aspect-ratio: 16 / 9; margin: 10px 0; border: 0; }
.rich img { display: inline-block; vertical-align: top; }

/* trang acc (máy tính): chia đôi 6-6; cột trái hiện đầy đủ ảnh; cột ngắn hơn dính theo khi cuộn (site.js tính chỗ dính) */
.pd-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
.pd-gallery, .pd-side { position: sticky; top: calc(var(--header-h) + 16px); min-width: 0; }
.pd-gallery { display: flex; flex-direction: column; gap: 12px; }
.pd-gallery .pd-main { max-height: none; }
.pd-gallery .pd-main img { display: block; width: 100%; height: auto; max-height: none; }
.pd-gallery .pd-main + .pd-main::after { display: none; }
.pd-side { display: flex; flex-direction: column; gap: 18px; }
.pd-side .pd-info { position: static; }
@media (max-width: 767px) {
  .pd-top { grid-template-columns: 1fr; }
  .pd-gallery, .pd-side { position: static; }
}
.pd-tabs .tab-head { overflow-x: auto; scrollbar-width: none; }
.pd-tabs .tab-head::-webkit-scrollbar { display: none; }
.pd-tabs .tab-head button { flex: none; white-space: nowrap; }
.tab-empty { color: var(--muted); font-style: italic; }
