/* ==========================================================================
   G&B Hair — Website tóc thật cao cấp
   File: css/style.css   (dùng chung cho cả 6 trang)
   --------------------------------------------------------------------------
   KHÔNG phụ thuộc thư viện ngoài. Không CDN. Mở file trực tiếp vẫn chạy.

   MỤC LỤC
   01. Biến CSS (Design Tokens)
   02. Reset & Base
   03. Tiện ích dùng chung
   04. Layout: container, section
   05. Buttons
   06. Icon SVG
   07. Header & Navigation (menu mobile bằng CSS thuần)
   08. Breadcrumb
   09. Hero (trang chủ)
   10. Page header (các trang con)
   11. Marquee — thanh cam kết
   12. Carousel — trượt ngang bằng CSS scroll-snap
   13. Cards: sản phẩm, phân loại, tính năng
   14. Gallery & Reels (thư viện ảnh / video)
   15. Timeline — quy trình
   16. About — giới thiệu
   17. Testimonials — đánh giá
   18. FAQ — dùng thẻ <details> gốc, không cần JS
   19. Contact — trang liên hệ
   20. CTA cuối trang
   21. Footer
   22. Floating Buttons
   23. Modal (xem ảnh lớn) + 23b. Reel feed (xem video dạng cuộn dọc)
   24. Scroll Reveal
   25. Accessibility & Motion Preferences
   ========================================================================== */


/* ==========================================================================
   01. BIẾN CSS — chỉnh toàn bộ giao diện chỉ từ khối này
   ========================================================================== */
:root {
  /* ---------- Màu thương hiệu (lấy từ logo G&B Hair: #7E130B) ---------- */
  --color-primary: #7E130B;
  --color-primary-dark: #5A0D07;
  --color-primary-light: #A81C10;
  --color-secondary: #D9A79E;
  --color-secondary-light: #F0D5CF;
  --color-bg: #FFFFFF;
  --color-text: #332B2A;
  --color-accent: #FBF3F1;

  /* ---------- Màu phụ trợ ---------- */
  --color-text-soft: #6B5854;
  --color-text-muted: #8C7A76;
  --color-heading: #2A120F;
  --color-border: #EDDCD8;
  --color-border-soft: #F6E9E6;
  --color-white: #FFFFFF;
  --color-dark: #1E0D0B;
  --color-success: #2E7D5B;
  --color-sale: #B8862B;
  --color-wa: #25D366;
  --color-wa-dark: #128C7E;
  /* Gradient gốc của Instagram — màu bắt buộc của hãng, chỉ dùng cho nút nổi Instagram */
  --gradient-ig: radial-gradient(circle at 30% 107%, #FDF497 0%, #FDF497 5%, #FD5949 45%, #D6249F 60%, #285AEB 90%);
  --color-star: #E0A64B;

  /* ---------- Gradient ---------- */
  --gradient-primary: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  --gradient-soft: linear-gradient(180deg, #FFFFFF 0%, var(--color-accent) 100%);
  --gradient-text: linear-gradient(120deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  --gradient-overlay: linear-gradient(180deg, rgba(30, 13, 11, 0) 35%, rgba(30, 13, 11, .74) 100%);

  /* ---------- Typography — font hệ thống, không tải từ mạng ---------- */
  --font-base: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
               'Helvetica Neue', Arial, 'Noto Sans', sans-serif;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;
  --fw-extrabold: 800;

  /* Font-size tự co giãn theo bề ngang màn hình */
  --fs-xs: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-md: 1.0625rem;
  --fs-lg: clamp(1.125rem, 0.4vw + 1rem, 1.25rem);
  --fs-xl: clamp(1.25rem, 0.6vw + 1.1rem, 1.5rem);
  --fs-h3: clamp(1.125rem, 0.6vw + 1rem, 1.375rem);
  --fs-h2: clamp(1.75rem, 2vw + 1.1rem, 2.75rem);
  --fs-h1: clamp(2rem, 3.2vw + 1.1rem, 3.5rem);

  --lh-tight: 1.15;
  --lh-heading: 1.25;
  --lh-base: 1.7;
  --ls-tight: -0.02em;
  --ls-wide: 0.08em;

  /* ---------- Khoảng cách ---------- */
  --space-2xs: 0.25rem;
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --section-py: clamp(3.5rem, 6vw, 6.5rem);

  /* ---------- Layout ---------- */
  --container: 1240px;
  --container-narrow: 860px;
  --gutter: clamp(1rem, 4vw, 2.5rem);
  --header-h: 88px;
  --header-h-scrolled: 72px;

  /* ---------- Bo góc ---------- */
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-pill: 999px;
  --radius-circle: 50%;

  /* ---------- Shadow ---------- */
  --shadow-xs: 0 1px 2px rgba(42, 18, 15, .06);
  --shadow-sm: 0 2px 8px rgba(42, 18, 15, .07);
  --shadow-md: 0 8px 24px rgba(42, 18, 15, .09);
  --shadow-lg: 0 18px 46px rgba(42, 18, 15, .13);
  --shadow-xl: 0 28px 70px rgba(42, 18, 15, .18);
  --shadow-primary: 0 12px 28px rgba(126, 19, 11, .30);
  --shadow-header: 0 4px 24px rgba(42, 18, 15, .08);

  /* ---------- Transition ---------- */
  --ease: cubic-bezier(.22, .61, .36, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --t-fast: .18s var(--ease);
  --t-base: .32s var(--ease);
  --t-slow: .6s var(--ease-out);

  /* ---------- Glassmorphism (rất nhẹ) ---------- */
  --glass-bg: rgba(255, 255, 255, .78);
  --glass-border: rgba(255, 255, 255, .55);
  --glass-blur: blur(14px);

  /* ---------- Z-index ----------
     Lưu ý thứ tự: .header tạo một "stacking context" riêng, nên menu mobile
     và lớp phủ nằm BÊN TRONG nó phải dùng số nhỏ, còn bản thân .header phải
     cao hơn .floating — nếu không nút WhatsApp nổi sẽ đè lên menu. */
  --z-base: 1;
  --z-overlay: 1;      /* lớp phủ — bên trong .header */
  --z-nav: 2;          /* ngăn menu   — bên trong .header */
  --z-floating: 200;
  --z-header: 300;
  --z-modal: 500;
}


/* ==========================================================================
   02. RESET & BASE
   ========================================================================== */
*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; padding: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h-scrolled) + 16px);
  /* `clip` chứ KHÔNG dùng `overflow-x: hidden`: hidden sẽ biến phần tử thành
     vùng cuộn và làm hỏng position:sticky của header. clip thì không. */
  overflow-x: clip;
}

body {
  font-family: var(--font-base);
  font-size: var(--fs-md);
  font-weight: var(--fw-regular);
  line-height: var(--lh-base);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Khoá cuộn khi mở menu mobile, feed video hoặc ngăn kéo lọc.
   JS gắn class lên <body>, nhưng phải khoá ở <html>: vì <html> đang có overflow-x: clip
   (không phải visible), overflow của <body> KHÔNG được đẩy lên khung nhìn — đặt
   overflow: hidden trên <body> sẽ biến body thành vùng cuộn riêng, header sticky bám theo
   body và trôi mất khỏi màn hình cùng menu 3 gạch bên trong (lỗi đã gặp 27/09/2026). */
html:has(> body.is-locked),
html:has(> body.is-filter-open) { overflow: hidden; }

img, picture, video, svg {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--t-fast);
}

ul, ol { list-style: none; }

button, input, textarea, select { font: inherit; color: inherit; }

button {
  background: none;
  border: 0;
  cursor: pointer;
}

address { font-style: normal; }

h1, h2, h3, h4, h5, h6 {
  color: var(--color-heading);
  font-weight: var(--fw-bold);
  line-height: var(--lh-heading);
  letter-spacing: var(--ls-tight);
}

::selection {
  background: var(--color-secondary);
  color: var(--color-dark);
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--color-accent); }
::-webkit-scrollbar-thumb {
  background: var(--color-secondary);
  border-radius: var(--radius-pill);
}
::-webkit-scrollbar-thumb:hover { background: var(--color-primary); }


/* ==========================================================================
   03. TIỆN ÍCH DÙNG CHUNG
   ========================================================================== */

/* Chỉ dành cho screen reader */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link — hiện khi focus bằng bàn phím */
.skip-link {
  position: fixed;
  top: -100px;
  left: var(--space-md);
  z-index: 999;
  padding: var(--space-sm) var(--space-lg);
  background: var(--color-primary);
  color: var(--color-white);
  font-weight: var(--fw-semibold);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  transition: top var(--t-base);
}
.skip-link:focus-visible { top: 0; }

/* Nhãn nhỏ phía trên tiêu đề */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: var(--space-md);
}
.eyebrow--center { justify-content: center; }

.text-gradient {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Sao đánh giá */
.rating {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: var(--color-star);
}
.rating .icon { width: 15px; height: 15px; }
.rating b {
  margin-left: var(--space-2xs);
  font-size: var(--fs-sm);
  color: var(--color-heading);
  font-weight: var(--fw-semibold);
}


/* ==========================================================================
   04. LAYOUT
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: var(--container-narrow); }

.section { padding-block: var(--section-py); }
/* Section nằm ngay dưới .page-head (đã có đệm dưới riêng) — bớt khoảng trên cho khỏi hở */
.section--after-head { padding-top: clamp(2.25rem, 4vw, 3.25rem); }
.section--accent { background: var(--color-accent); }

.section__head {
  max-width: 720px;
  margin: 0 auto clamp(2rem, 4vw, 3.5rem);
  text-align: center;
}
.section__title {
  font-size: var(--fs-h2);
  font-weight: var(--fw-extrabold);
  margin-bottom: var(--space-md);
}
.section__sub {
  color: var(--color-text-soft);
  font-size: var(--fs-lg);
}
.section__foot {
  display: flex;
  justify-content: center;
  margin-top: clamp(2rem, 4vw, 3rem);
}


/* ==========================================================================
   05. BUTTONS
   ========================================================================== */
.btn {
  white-space: nowrap;
  --btn-py: 0.875rem;
  --btn-px: 1.75rem;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-xs);
  padding: var(--btn-py) var(--btn-px);
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  line-height: 1.2;
  text-align: center;
  border-radius: var(--radius-pill);
  border: 1.5px solid transparent;
  cursor: pointer;
  overflow: hidden;
  transition: transform var(--t-base), box-shadow var(--t-base),
              background-color var(--t-base), color var(--t-base),
              border-color var(--t-base);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn--sm { --btn-py: 0.625rem; --btn-px: 1.25rem; font-size: var(--fs-sm); }
.btn--lg { --btn-py: 1.0625rem; --btn-px: 2.25rem; }

.btn--primary {
  background: var(--gradient-primary);
  color: var(--color-white);
  box-shadow: var(--shadow-primary);
}
.btn--primary:hover { box-shadow: 0 16px 34px rgba(126, 19, 11, .36); }

.btn--ghost {
  background: var(--color-white);
  color: var(--color-primary);
  border-color: var(--color-border);
  box-shadow: var(--shadow-sm);
}
.btn--ghost:hover { border-color: var(--color-primary); box-shadow: var(--shadow-md); }

.btn--outline {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn--outline:hover { background: var(--color-primary); color: var(--color-white); }



/* Hiệu ứng gợn sóng khi bấm — do js/main.js tạo, không có JS vẫn bấm được */
.ripple {
  position: absolute;
  border-radius: var(--radius-circle);
  background: rgba(255, 255, 255, .45);
  transform: scale(0);
  animation: ripple-out .6s var(--ease-out) forwards;
  pointer-events: none;
}
.btn--ghost .ripple,
.btn--outline .ripple { background: rgba(126, 19, 11, .16); }

@keyframes ripple-out {
  to { transform: scale(2.6); opacity: 0; }
}


/* ==========================================================================
   06. ICON SVG
   Mỗi trang nhúng sẵn một "sprite" ở đầu <body>; dùng lại bằng
   <svg class="icon"><use href="#i-ten-icon"></use></svg>
   ========================================================================== */
.icon {
  width: 1.15em;
  height: 1.15em;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  /* Icon dạng khối đặc (sao, play, WhatsApp) tự ghi đè bằng .icon--solid */
}
/* Icon vẽ bằng vùng đặc thay vì nét viền */
.icon--solid { fill: currentColor; stroke: none; }

/* Khối chứa sprite — ẩn hoàn toàn nhưng vẫn dùng được qua <use> */
.svg-sprite {
  position: absolute;
  width: 0; height: 0;
  overflow: hidden;
}


/* ==========================================================================
   07. HEADER & NAVIGATION
   Menu mobile chạy bằng CSS thuần (checkbox), không cần JavaScript.
   ========================================================================== */
.header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  background: var(--color-white);
  border-bottom: 1px solid var(--color-border-soft);
  transition: box-shadow var(--t-base), background-color var(--t-base);
}
/* JS thêm class này khi cuộn xuống — chỉ là tô điểm thêm */
.header.is-scrolled {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  box-shadow: var(--shadow-header);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-lg);
  height: var(--header-h);
  transition: height var(--t-base);
}
.header.is-scrolled .header__inner { height: var(--header-h-scrolled); }

/* Ô checkbox điều khiển menu mobile — luôn ẩn khỏi mắt người dùng */
.nav-toggle {
  position: absolute;
  opacity: 0;
  width: 0; height: 0;
  pointer-events: none;
}

/* ---------- Logo ---------- */
.logo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  flex-shrink: 0;
}
/* Logo ngang — dùng nguyên file ngang.png của thương hiệu */
.logo__full {
  display: block;
  height: 50px;
  width: auto;
  object-fit: contain;
  transition: height var(--t-base);
}
.header.is-scrolled .logo__full { height: 42px; }

/* Footer nền đỏ sậm — dùng bản dương (Ngang trawsng.png) */
.logo__full--footer { height: 62px; }
.header.is-scrolled .logo__full--footer { height: 62px; }

/* ---------- Nav ---------- */
.nav__list {
  display: flex;
  align-items: center;
  gap: clamp(0.35rem, 0.85vw, 0.85rem);
}
.nav__link {
  position: relative;
  display: inline-block;
  padding: var(--space-xs) var(--space-2xs);
  font-size: clamp(0.8125rem, 0.55vw + 0.55rem, 0.9375rem);
  font-weight: var(--fw-medium);
  white-space: nowrap;
}
.nav__link::after {
  content: '';
  position: absolute;
  left: 0; bottom: 2px;
  width: 100%;
  height: 2px;
  border-radius: var(--radius-pill);
  background: var(--gradient-primary);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--t-base);
}
/* .is-active được gắn thủ công trong HTML của từng trang */
.nav__link:hover,
.nav__link.is-active { color: var(--color-primary); }
.nav__link:hover::after,
.nav__link.is-active::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav__cta-mobile { display: none; }

.header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

/* ---------- Hamburger (là <label>, hoạt động không cần JS) ---------- */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px; height: 44px;
  padding: 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background-color var(--t-fast);
}
.hamburger:hover { background: var(--color-accent); }
.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: var(--radius-pill);
  background: var(--color-heading);
  transition: transform var(--t-base), opacity var(--t-fast);
}
/* Biến thành dấu X khi menu mở */
.nav-toggle:checked ~ .header__inner .hamburger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle:checked ~ .header__inner .hamburger span:nth-child(2) { opacity: 0; }
.nav-toggle:checked ~ .header__inner .hamburger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Lớp phủ khi mở menu ---------- */
.nav-overlay {
  position: fixed;
  inset: 0;
  z-index: var(--z-overlay);
  display: none;
  background: rgba(30, 13, 11, .5);
  cursor: pointer;
}


/* ==========================================================================
   08. BREADCRUMB
   ========================================================================== */
.breadcrumb {
  padding-block: var(--space-md);
  background: var(--color-accent);
  border-bottom: 1px solid var(--color-border-soft);
  font-size: var(--fs-sm);
}
.breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-xs);
  color: var(--color-text-muted);
}
.breadcrumb__list li {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}
/* Dấu phân cách giữa các mục */
.breadcrumb__list li + li::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: var(--radius-circle);
  background: var(--color-secondary);
}
.breadcrumb__list a:hover { color: var(--color-primary); }
.breadcrumb__list [aria-current] {
  color: var(--color-heading);
  font-weight: var(--fw-medium);
}


/* ==========================================================================
   09. HERO (chỉ dùng ở trang chủ)
   ========================================================================== */
.hero {
  position: relative;
  padding-block: clamp(2.5rem, 5vw, 4.5rem) clamp(3rem, 6vw, 5.5rem);
  background: var(--gradient-soft);
  overflow: hidden;
}
.hero__blob {
  position: absolute;
  border-radius: var(--radius-circle);
  filter: blur(90px);
  opacity: .5;
  pointer-events: none;
}
.hero__blob--1 {
  top: -120px; right: -80px;
  width: 460px; height: 460px;
  background: var(--color-secondary);
}
.hero__blob--2 {
  bottom: -160px; left: -120px;
  width: 400px; height: 400px;
  background: var(--color-secondary-light);
}

.hero__inner {
  position: relative;
  z-index: var(--z-base);
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;   /* cột ảnh hẹp hơn vì ảnh dọc 9:16 */
  align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
}

.hero__title {
  font-size: var(--fs-h1);
  font-weight: var(--fw-extrabold);
  line-height: var(--lh-tight);
  margin-bottom: var(--space-lg);
}
.hero__desc {
  max-width: 54ch;
  font-size: var(--fs-lg);
  color: var(--color-text-soft);
  margin-bottom: var(--space-xl);
}

.hero__usp {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-lg);
  margin-bottom: var(--space-xl);
}
.hero__usp li {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-weight: var(--fw-medium);
  color: var(--color-heading);
}
.hero__usp .icon {
  width: 22px; height: 22px;
  padding: 4px;
  border-radius: var(--radius-circle);
  background: var(--color-primary);
  color: var(--color-white);
  stroke-width: 3;
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md);
  margin-bottom: clamp(2rem, 4vw, 3rem);
}

/* Biến thể căn giữa — nút "Xem thêm câu hỏi" cuối FAQ trang chủ */
.hero__cta--center { justify-content: center; margin-bottom: 0; }
.faq-more { margin-top: var(--space-xl); }

/* Thống kê hero trang chủ: 2 mục (Khách hàng · Mã màu nhuộm) chia đều 2 nửa, căn giữa.
   Mục "Đánh giá" đã xoá 27/09/2026. */
.hero__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  text-align: center;
  gap: clamp(1.5rem, 4vw, 3rem);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--color-border);
}
.hero__stat dt {
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  margin-bottom: 2px;
}
.hero__stat dd {
  font-size: var(--fs-xl);
  font-weight: var(--fw-extrabold);
  color: var(--color-primary);
  letter-spacing: var(--ls-tight);
}

/* ---------- Slider ảnh Hero ----------
   Không có JS: chỉ hiện slide đầu tiên (đã gắn sẵn .is-active trong HTML).
   Có JS: js/slider.js luân phiên đổi slide bằng cách chuyển class. */
/* Khung dọc 9:16 (ảnh bìa video). Giới hạn bề rộng để khung không cao quá màn hình. */
.hero__media {
  position: relative;
  justify-self: center;
  width: min(100%, 360px, calc((100svh - var(--header-h) - 3rem) * 9 / 16));
  min-width: 240px;
}

.hero-slider {
  position: relative;
  aspect-ratio: 9 / 16;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--color-accent);
  box-shadow: var(--shadow-xl);
}
.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .8s var(--ease-out), visibility .8s;
}
.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
}
.hero-slide img,
.hero-slide__video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: var(--color-dark);
}

/* Hai nút mũi tên hai bên khung video (JS tạo, dùng chung kiểu .carousel__btn) */
.hero-nav { top: 50%; }
.hero-nav--prev { left: -23px; }
.hero-nav--next { right: -23px; }
.hero-slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-overlay);
}
.hero-slide__caption {
  position: absolute;
  left: var(--space-md);
  right: var(--space-md);
  bottom: calc(var(--space-md) + 22px);   /* chừa chỗ cho chấm chuyển slide */
  z-index: 2;
  color: var(--color-white);
}
.hero-slide__tag {
  display: inline-block;
  padding: 4px 12px;
  margin-bottom: var(--space-xs);
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, .22);
  border: 1px solid rgba(255, 255, 255, .35);
}
.hero-slide__name {
  font-size: clamp(1rem, 1.3vw + .5rem, 1.25rem);
  font-weight: var(--fw-semibold);
  line-height: 1.3;
  text-wrap: balance;
}

/* Chấm điều hướng — JS tạo; không có JS thì không hiển thị gì */
.hero-dots {
  position: absolute;
  left: 50%;
  bottom: var(--space-md);
  z-index: 3;
  display: flex;
  gap: var(--space-xs);
  transform: translateX(-50%);
}
.hero-dots button {
  width: 8px; height: 8px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, .55);
  transition: width var(--t-base), background-color var(--t-base);
}
.hero-dots button.is-active {
  width: 26px;
  background: var(--color-secondary);
}

/* Thẻ cam kết nổi cạnh ảnh */


/* ==========================================================================
   09b. COVER SLIDER — hero đầu trang chủ
   Hero KHÔNG dùng ảnh — thiết kế typography + mảng màu thương hiệu (phương án B,
   chốt 26/09/2026): nền tối một màu, chữ ở giữa, chữ lớn viền rỗng chìm phía sau.
   Các slide chồng lên nhau trong cùng một ô lưới nên chiều cao tự theo nội dung.
   ========================================================================== */
.cover-slider {
  position: relative;
  display: grid;
  width: 100%;
  overflow: hidden;
  isolation: isolate;
  color: var(--color-white);
  background:
    radial-gradient(ellipse 60% 70% at 50% 115%, color-mix(in srgb, var(--color-primary) 70%, transparent), transparent 70%),
    radial-gradient(ellipse 45% 55% at 105% -5%, color-mix(in srgb, var(--color-primary-dark) 80%, transparent), transparent 70%),
    var(--color-dark);
}

.cover-slide {
  grid-area: 1 / 1;
  position: relative;
  opacity: 0;
  visibility: hidden;
  transition: opacity .8s var(--ease), visibility .8s var(--ease);
}
.cover-slide.is-active { opacity: 1; visibility: visible; }

.cover-slide__inner {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  min-height: clamp(480px, 74vh, 700px);
  padding-block: clamp(3.5rem, 7vw, 5rem) clamp(4.5rem, 8vw, 6rem);
  text-align: center;
}
.cover-slide__text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
  max-width: 54rem;
}

/* Nhãn kẹp giữa 2 đường kẻ mảnh */
.cover-slide__tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  color: var(--color-secondary);
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
}
.cover-slide__tag .icon { width: 16px; height: 16px; }
.cover-slide__tag::before,
.cover-slide__tag::after {
  content: '';
  width: clamp(24px, 6vw, 56px);
  height: 1px;
  background: color-mix(in srgb, var(--color-secondary) 60%, transparent);
}
.cover-slide__tag::before { margin-right: var(--space-xs); }
.cover-slide__tag::after  { margin-left: var(--space-xs); }

.cover-slide__title {
  font-size: clamp(2.6rem, 5.6vw + .5rem, 5.75rem);
  font-weight: var(--fw-extrabold);
  line-height: 1.04;
  letter-spacing: -0.03em;
  color: var(--color-white);
  text-wrap: balance;
}
.cover-slide__desc {
  max-width: 34rem;
  margin-inline: auto;
  font-size: var(--fs-lg);
  color: rgba(255, 255, 255, .8);
}
.cover-slide__text .btn { margin-top: var(--space-xs); }

/* Chữ trượt lên nhẹ khi slide xuất hiện (chỉ khi JS chạy) */
.js .cover-slide .cover-slide__text > * {
  transform: translateY(14px);
  opacity: 0;
  transition: transform .7s var(--ease-out), opacity .7s var(--ease-out);
}
.js .cover-slide.is-active .cover-slide__text > * { transform: none; opacity: 1; }
.js .cover-slide.is-active .cover-slide__text > :nth-child(2) { transition-delay: .08s; }
.js .cover-slide.is-active .cover-slide__text > :nth-child(3) { transition-delay: .16s; }
.js .cover-slide.is-active .cover-slide__text > :nth-child(4) { transition-delay: .24s; }

/* Chữ lớn viền rỗng chìm phía sau */
.cover-word {
  position: absolute;
  left: 50%; top: 50%;
  z-index: -1;
  translate: -50% -50%;
  font-size: clamp(5rem, 19vw, 17rem);
  font-weight: var(--fw-extrabold);
  line-height: 1;
  letter-spacing: -0.03em;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px color-mix(in srgb, var(--color-secondary) 22%, transparent);
  pointer-events: none;
  user-select: none;
}

/* Hai góc khung trang trí */
.cover-corner {
  position: absolute;
  z-index: 1;
  width: clamp(36px, 6vw, 72px);
  height: clamp(36px, 6vw, 72px);
  border: 0 solid color-mix(in srgb, var(--color-secondary) 45%, transparent);
  pointer-events: none;
}
.cover-corner--tl { top: clamp(1.25rem, 3vw, 2.25rem); left: clamp(1.25rem, 3vw, 2.25rem); border-top-width: 1px; border-left-width: 1px; }
.cover-corner--br { bottom: clamp(1.25rem, 3vw, 2.25rem); right: clamp(1.25rem, 3vw, 2.25rem); border-bottom-width: 1px; border-right-width: 1px; }

/* ---------- Hai nút mũi tên ---------- */
.cover-slider__btn {
  position: absolute;
  top: 50%;
  z-index: 3;
  translate: 0 -50%;
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  border-radius: var(--radius-circle);
  border: 1px solid rgba(255, 255, 255, .35);
  background: rgba(30, 13, 11, .38);
  color: var(--color-white);
  cursor: pointer;
  opacity: 0;
  transition: opacity var(--t-base), background var(--t-base), transform var(--t-base);
  backdrop-filter: blur(6px);
}
.cover-slider:hover .cover-slider__btn,
.cover-slider:focus-within .cover-slider__btn { opacity: 1; }
.cover-slider__btn:hover { background: var(--color-primary); transform: scale(1.08); }
.cover-slider__btn:focus-visible { opacity: 1; outline: 2px solid var(--color-white); outline-offset: 3px; }
.cover-slider__btn--prev { left: clamp(.75rem, 2vw, 1.5rem); }
.cover-slider__btn--next { right: clamp(.75rem, 2vw, 1.5rem); }
.cover-slider__btn .icon { width: 22px; height: 22px; }

/* ---------- Chấm chỉ báo ---------- */
.cover-dots {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: clamp(1rem, 3vw, 1.75rem);
  translate: -50% 0;
  display: flex;
  gap: var(--space-xs);
}
.cover-dots button {
  width: 30px; height: 4px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, .45);
  cursor: pointer;
  transition: background var(--t-base), width var(--t-base);
}
.cover-dots button.is-active { background: var(--color-white); width: 48px; }
.cover-dots button:focus-visible { outline: 2px solid var(--color-white); outline-offset: 3px; }


/* ==========================================================================
   10. PAGE HEADER — phần mở đầu của các trang con
   ========================================================================== */
.page-head {
  position: relative;
  padding-block: clamp(2.5rem, 5vw, 4rem);
  background: var(--gradient-soft);
  text-align: center;
  overflow: hidden;
}
.page-head__inner {
  position: relative;
  z-index: var(--z-base);
  max-width: 760px;
  margin-inline: auto;
}
.page-head__title {
  font-size: var(--fs-h1);
  font-weight: var(--fw-extrabold);
  margin-bottom: var(--space-md);
}
.page-head__desc {
  font-size: var(--fs-lg);
  color: var(--color-text-soft);
}


/* ==========================================================================
   11. MARQUEE — thanh cam kết
   ========================================================================== */
.marquee {
  /* Tông nhạt (27/09/2026, thay nền nâu đen): hoà với các section trắng quanh nó,
     chỉ tách bằng 2 viền mảnh — không còn cảm giác một dải đen ngắt quãng trang. */
  background: var(--color-accent);
  color: var(--color-text);
  border-block: 1px solid var(--color-border);
  padding-block: var(--space-md);
}
.marquee__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-evenly;   /* 3 mục cách đều nhau và cách đều hai mép */
  gap: var(--space-md) var(--space-xl);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
}
.marquee__inner span {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}
.marquee__inner .icon { color: var(--color-primary); }


/* ==========================================================================
   12. CAROUSEL — trượt ngang bằng CSS scroll-snap
   Không cần JS: người dùng vuốt hoặc cuộn ngang là được.
   Có JS: hai nút mũi tên gọi scrollBy() cho tiện trên desktop.
   ========================================================================== */
.carousel { position: relative; }

.carousel__track {
  display: flex;
  gap: var(--space-md);
  padding-block: var(--space-2xs) var(--space-md);
  padding-inline: var(--gutter);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-left: var(--gutter);
  scrollbar-width: none;               /* Firefox */
  -webkit-overflow-scrolling: touch;
}
.carousel__track::-webkit-scrollbar { display: none; }

.carousel__item {
  flex: 0 0 var(--card-w, 260px);
  scroll-snap-align: start;
}

/* Nút mũi tên — JS bỏ [hidden] khi khởi tạo xong */
.carousel__btn {
  position: absolute;
  top: 42%;
  z-index: 5;
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  transform: translateY(-50%);
  border-radius: var(--radius-circle);
  background: var(--glass-bg);
  border: 1px solid var(--color-border);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  color: var(--color-primary);
  box-shadow: var(--shadow-md);
  transition: background-color var(--t-base), color var(--t-base),
              transform var(--t-base), opacity var(--t-base);
}
.carousel__btn:hover { background: var(--color-primary); color: var(--color-white); }
.carousel__btn[disabled] { opacity: .3; pointer-events: none; }
.carousel__btn--prev { left: calc(var(--gutter) - 14px); }
.carousel__btn--next { right: calc(var(--gutter) - 14px); }
.carousel__btn--prev:hover { transform: translateY(-50%) translateX(-3px); }
.carousel__btn--next:hover { transform: translateY(-50%) translateX(3px); }

/* Gợi ý "vuốt để xem thêm" trên mobile */
.carousel__hint {
  display: none;
  margin-top: var(--space-xs);
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  text-align: center;
}


/* ==========================================================================
   13. CARDS
   ========================================================================== */

/* ---------- Lưới chung ---------- */
.grid {
  display: grid;
  gap: clamp(1rem, 2vw, 1.75rem);
}
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

/* ---------- Nhãn góc ảnh (ô sản phẩm products.html) ----------
   Màu theo loại nhãn nằm cạnh CSS .product-tile (mục 14). */
.badge {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  z-index: 2;
  padding: 5px 12px;
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  color: var(--color-white);
  border-radius: var(--radius-pill);
  box-shadow: var(--shadow-sm);
}
.badge--new  { background: var(--color-success); }

/* ---------- Card phân loại ---------- */
.cat-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  border-radius: var(--radius-lg);
  background: var(--color-white);
  border: 1px solid var(--color-border-soft);
  overflow: hidden;
  transition: transform var(--t-base), box-shadow var(--t-base), border-color var(--t-base);
}
.cat-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-secondary);
}

.cat-card__media {
  position: relative;
  aspect-ratio: 9 / 16;           /* dọc, đồng bộ lưới sản phẩm / thư viện (27/09/2026) */
  overflow: hidden;
  background: var(--color-accent);
}
.cat-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--t-slow);
}
.cat-card:hover .cat-card__media img { transform: scale(1.08); }

.cat-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: var(--space-lg);      /* icon tròn đè mép ảnh đã xoá 27/09/2026 — bỏ khoảng chừa cho nó */
}
.cat-card__title {
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}
.cat-card__desc {
  font-size: var(--fs-sm);
  color: var(--color-text-soft);
  margin-bottom: var(--space-md);
}

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  margin-top: auto;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: var(--color-primary);
}
.arrow-link .icon { transition: transform var(--t-base); }
.arrow-link:hover .icon { transform: translateX(5px); }

/* ---------- Danh sách tính năng (vì sao chọn chúng tôi) ---------- */
.feature-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  /* 5 mục: xếp theo CỘT (trái 3, phải 2) thay vì theo hàng — tránh mục lẻ
     nằm một mình ở hàng cuối (còn 5 mục từ 27/09/2026). */
  grid-template-rows: repeat(3, auto);
  grid-auto-flow: column;
  gap: var(--space-lg);
}
.feature-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
}
.feature-item__icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 44px; height: 44px;
  border-radius: var(--radius-md);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  color: var(--color-primary);
  transition: background-color var(--t-base), color var(--t-base),
              transform var(--t-base), border-color var(--t-base);
}
.feature-item__icon .icon { width: 21px; height: 21px; }
.feature-item:hover .feature-item__icon {
  background: var(--gradient-primary);
  border-color: transparent;
  color: var(--color-white);
  transform: translateY(-3px);
}
.feature-item__title {
  font-size: var(--fs-base);
  margin-bottom: 2px;
}
.feature-item p {
  font-size: var(--fs-sm);
  color: var(--color-text-soft);
}


/* ==========================================================================
   13b. FILTER — sidebar lọc sản phẩm (chọn một mục tại một thời điểm)
   Desktop: 2 cột (sidebar trái ~25% / lưới phải ~75%)
   Dưới 768px: sidebar ẩn, mở dạng ngăn kéo trượt từ trái
   ========================================================================== */

/* ---------- Bố cục 2 cột ---------- */
.shop {
  display: grid;
  grid-template-columns: minmax(230px, 25%) 1fr;
  align-items: start;
  gap: clamp(1.5rem, 2.5vw, 2.5rem);
}
.shop__main { min-width: 0; }

/* ---------- Khung sidebar ---------- */
.filter__panel {
  border: 1px solid #E5E5E5;
  border-radius: 8px;
  background: var(--color-white);
  overflow: hidden;
}

.filter__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-lg);
  background: var(--color-accent);
  border-bottom: 1px solid #E5E5E5;
}
.filter__title {
  margin: 0;
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--color-heading);
}

/* Nút đóng chỉ dùng ở bản ngăn kéo trên máy nhỏ */
.filter__close {
  display: none;
  place-items: center;
  width: 32px; height: 32px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-circle);
  background: transparent;
  color: var(--color-text-soft);
  cursor: pointer;
  transition: background var(--t-fast), color var(--t-fast);
}
.filter__close:hover { background: var(--color-border-soft); color: var(--color-primary); }
.filter__close .icon { width: 18px; height: 18px; }

/* ---------- Nhóm và danh sách lựa chọn ---------- */
.filter__list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.filter__list--all {
  padding: var(--space-xs) 0;
  border-bottom: 1px solid #E5E5E5;
}

.filter__group { padding: var(--space-md) 0 var(--space-xs); }
.filter__group + .filter__group { border-top: 1px solid #E5E5E5; }

.filter__label {
  margin: 0 0 var(--space-2xs);
  padding: 0 var(--space-lg);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-soft);
}

.filter__item + .filter__item .filter__opt {
  border-top: 1px dashed var(--color-border);
}

.filter__opt {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  width: 100%;
  padding: 0.6rem var(--space-lg);
  border: 0;
  background: transparent;
  color: var(--color-text-soft);
  font-family: inherit;
  font-size: var(--fs-sm);
  font-weight: var(--fw-regular);
  text-align: left;
  cursor: pointer;
  transition: color var(--t-fast), background var(--t-fast);
}
.filter__opt:hover { color: var(--color-primary); }
.filter__opt:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: -3px;
}

/* Ô vuông nhỏ đứng trước mỗi lựa chọn */
.filter__bullet {
  flex-shrink: 0;
  width: 6px; height: 6px;
  background: var(--color-text-muted);
  transition: background var(--t-fast);
}
/* Chấm tròn cho mục "Tất cả sản phẩm" */
.filter__dot {
  flex-shrink: 0;
  width: 8px; height: 8px;
  border: 2px solid var(--color-text-muted);
  border-radius: var(--radius-circle);
  transition: border-color var(--t-fast), background var(--t-fast);
}
.filter__opt--all {
  font-weight: var(--fw-medium);
  color: var(--color-heading);
}

/* Mục đang lọc */
.filter__opt.is-active {
  background: var(--color-accent);
  color: var(--color-primary);
  font-weight: var(--fw-semibold);
}
.filter__opt.is-active .filter__bullet { background: var(--color-primary); }
.filter__opt.is-active .filter__dot {
  border-color: var(--color-primary);
  background: var(--color-primary);
}

/* ---------- Nút mở ngăn kéo (chỉ hiện trên máy nhỏ) ---------- */
.filter__toggle {
  display: none;
  align-items: center;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
  padding: 0.65rem 1.2rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-white);
  color: var(--color-heading);
  font-family: inherit;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  cursor: pointer;
}
.filter__toggle .icon { width: 18px; height: 18px; color: var(--color-primary); }

.filter__backdrop { display: none; }

/* ---------- Ghi chú, bộ đếm, trạng thái rỗng ---------- */
.filter__note {
  display: flex;
  align-items: flex-start;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  border-left: 3px solid var(--color-primary);
  border-radius: var(--radius-xs);
  background: var(--color-accent);
  font-size: var(--fs-sm);
  color: var(--color-text-soft);
}
.filter__note[hidden] { display: none; }
.filter__note .icon { flex-shrink: 0; margin-top: .15em; color: var(--color-primary); }

.filter__count {
  margin-bottom: var(--space-md);
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
}

.product-empty {
  grid-column: 1 / -1;
  padding: var(--space-2xl) var(--space-lg);
  text-align: center;
  color: var(--color-text-soft);
  background: var(--color-accent);
  border-radius: var(--radius-lg);
}
.product-empty a { font-weight: var(--fw-semibold); }
.product-empty code {
  padding: .1em .4em;
  border-radius: var(--radius-xs);
  background: var(--color-white);
  font-size: .92em;
}

/* Dòng dẫn sang Thư viện dưới lưới sản phẩm */
.section__foot-link {
  margin-top: clamp(2rem, 4vw, 3rem);
  text-align: center;
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
}
.section__foot-link a {
  font-weight: var(--fw-semibold);
  color: var(--color-primary);
}

/* ==========================================================================
   14. GALLERY & REELS
   ========================================================================== */

/* ---------- Thẻ ảnh trong thư viện ---------- */
.gallery-card {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--color-accent);
  box-shadow: var(--shadow-sm);
  transition: transform var(--t-base), box-shadow var(--t-base);
}
.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--t-slow);
}
.gallery-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-overlay);
  opacity: .8;
  transition: opacity var(--t-base);
}
.gallery-card:hover,
.gallery-card:focus-visible {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.gallery-card:hover img,
.gallery-card:focus-visible img { transform: scale(1.07); }
.gallery-card:hover::after { opacity: 1; }

.gallery-card__zoom {
  position: absolute;
  top: 50%; left: 50%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 52px; height: 52px;
  border-radius: var(--radius-circle);
  background: var(--glass-bg);
  color: var(--color-primary);
  border: 1px solid var(--glass-border);
  opacity: 0;
  transform: translate(-50%, -50%) scale(.7);
  transition: opacity var(--t-base), transform var(--t-base);
}
.gallery-card:hover .gallery-card__zoom,
.gallery-card:focus-visible .gallery-card__zoom {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.gallery-card__label {
  position: absolute;
  left: var(--space-md);
  right: var(--space-md);
  bottom: var(--space-md);
  z-index: 2;
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: var(--color-white);
}

/* ---------- Lưới compact 9:16 kiểu Instagram ----------
   Dùng chung cho gallery.html (#videoWall) và products.html (#productGrid),
   ô do js/product-grid.js dựng. Số cột: 5 (> 1024px) · 4 (≤ 1024px) · 3 (≤ 768px,
   tràn sát mép màn hình như Instagram) — xem responsive.css.
   Mỗi ô là một container (container-type) nên chữ bên trong co theo bề rộng ô
   bằng đơn vị cqi, không phụ thuộc bề rộng màn hình. */
.ig-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 3px;
}
.ig-tile {
  position: relative;
  aspect-ratio: 9 / 16;
  overflow: hidden;
  border-radius: 2px;
  background: var(--color-dark);
  container-type: inline-size;
}
.ig-tile__media {
  position: absolute;
  inset: 0;
  display: block;
}
.ig-tile__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--t-slow);
}
.ig-tile:hover .ig-tile__media img,
.ig-tile__media:focus-visible img { transform: scale(1.04); }
.ig-tile__media:focus-visible { outline-offset: -3px; }

/* Icon play nhỏ góc trên phải — đánh dấu ô là video (Thư viện) */
.ig-tile__play {
  position: absolute;
  top: 6px; right: 6px;
  color: var(--color-white);
  filter: drop-shadow(0 1px 3px rgba(30, 13, 11, .7));
  pointer-events: none;
}
.ig-tile__play .icon { width: 18px; height: 18px; }

/* ---------- Ô sản phẩm: chữ + nút đè lên nửa dưới ảnh ---------- */
.product-tile .badge {
  top: 6px; left: 6px;
  padding: 2px 8px;
  font-size: clamp(0.6875rem, 6.5cqi, 0.75rem);
  pointer-events: none;
}
.product-tile__info {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: clamp(2px, 2.5cqi, 6px);
  padding: 3.5rem clamp(6px, 6cqi, 12px) clamp(6px, 6cqi, 12px);
  /* Tối dần từ giữa xuống đáy để chữ trắng luôn đọc được trên mọi ảnh */
  background: linear-gradient(to top,
    rgba(30, 13, 11, .94) 0%, rgba(30, 13, 11, .82) 45%, rgba(30, 13, 11, 0) 100%);
  color: var(--color-white);
  pointer-events: none;          /* bấm vào vùng chữ vẫn mở video; chỉ nút bắt sự kiện */
}
.product-tile__name {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: clamp(0.75rem, 8cqi, 1rem);
  font-weight: var(--fw-bold);
  line-height: 1.25;
  color: var(--color-white);
}
.product-tile__desc {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: clamp(0.6875rem, 6.5cqi, 0.8125rem);
  line-height: 1.35;
  color: rgba(255, 255, 255, .82);
}
.product-tile__actions {
  display: flex;
  gap: 4px;
  margin-top: 2px;
  pointer-events: auto;
}
.product-tile__actions .btn {
  --btn-py: 0;
  height: clamp(28px, 17cqi, 38px);
  min-height: 0;
  font-size: clamp(0.6875rem, 6.5cqi, 0.8125rem);
  box-shadow: none;
}
.product-tile__quote { flex: 1; min-width: 0; --btn-px: 4px; }
.product-tile__actions .btn:hover { transform: none; }

/* Nhãn ô sản phẩm (gán bởi badgeFor() trong js/product-grid.js).
   Cao cấp = vàng đồng, Ưu đãi = đỏ thương hiệu — đổi chỗ cho nhau 27/09/2026.
   (.badge--new ở cạnh .badge, mục 13.) */
.badge--premium { background: var(--color-sale); }
.badge--deal    { background: var(--gradient-primary); }

/* Ô rất hẹp (điện thoại 3 cột): mô tả còn 1 dòng */
@container (max-width: 150px) {
  .product-tile__desc { -webkit-line-clamp: 1; }
}


/* ---------- Thanh phân trang dưới lưới: "1–50 trong số 172  ‹ ›" ---------- */
.pager {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-xs);
  margin-top: var(--space-md);
}
.pager[hidden] { display: none; }
.pager__info {
  margin-right: var(--space-sm);
  font-size: var(--fs-sm);
  color: var(--color-text-soft);
  font-variant-numeric: tabular-nums;
}
.pager__btn {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: var(--radius-circle);
  border: 1px solid var(--color-border);
  background: var(--color-white);
  color: var(--color-heading);
  cursor: pointer;
  transition: background-color var(--t-base), color var(--t-base), border-color var(--t-base);
}
.pager__btn .icon { width: 20px; height: 20px; }
.pager__btn:hover:not(:disabled) {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-white);
}
.pager__btn:disabled { opacity: .35; cursor: default; }


/* ==========================================================================
   15. TIMELINE — quy trình mua hàng
   ========================================================================== */
.timeline {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(1rem, 2vw, 2rem);
}
.timeline::before {
  content: '';
  position: absolute;
  top: 30px;
  left: 12%;
  right: 12%;
  height: 2px;
  background: repeating-linear-gradient(
    to right,
    var(--color-secondary) 0 10px,
    transparent 10px 20px
  );
}

.timeline__item {
  position: relative;
  z-index: var(--z-base);
  text-align: center;
}
.timeline__dot {
  display: grid;
  place-items: center;
  width: 60px; height: 60px;
  margin: 0 auto var(--space-md);
  border-radius: var(--radius-circle);
  background: var(--color-white);
  border: 2px solid var(--color-secondary);
  color: var(--color-primary);
  box-shadow: var(--shadow-sm);
  transition: transform var(--t-base), background-color var(--t-base),
              color var(--t-base), box-shadow var(--t-base), border-color var(--t-base);
}
.timeline__dot .icon { width: 24px; height: 24px; }
.timeline__item:hover .timeline__dot {
  background: var(--gradient-primary);
  border-color: transparent;
  color: var(--color-white);
  transform: translateY(-4px) scale(1.06);
  box-shadow: var(--shadow-primary);
}

.timeline__step {
  display: block;
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--color-secondary);
  margin-bottom: var(--space-2xs);
}
.timeline__title {
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}
.timeline__body p {
  font-size: var(--fs-sm);
  color: var(--color-text-soft);
  max-width: 34ch;
  margin-inline: auto;
}

/* Dòng ghi chú phụ trong mỗi bước — nhỏ và nhạt hơn phần mô tả chính */
.timeline__note {
  margin-top: var(--space-xs);
  padding-left: var(--space-sm);
  border-left: 2px solid var(--color-secondary);
  font-size: var(--fs-sm);
  color: var(--color-text-muted);
  text-align: left;       /* khối vẫn ở giữa cột, chữ bám sát vạch viền trái */
}


/* ==========================================================================
   16. ABOUT — giới thiệu
   ========================================================================== */
/* Chỉ còn khối chữ căn giữa — ảnh và nhãn "12 năm kinh nghiệm" đã xoá 27/09/2026 */
.about__inner {
  max-width: 760px;
  text-align: center;
}
.about__content .eyebrow { display: inline-flex; }
.about__lead {
  color: var(--color-text-soft);
  font-size: var(--fs-lg);
  margin-bottom: var(--space-lg);
}
.about__lead:last-child { margin-bottom: 0; }


/* ==========================================================================
   17. TESTIMONIALS — đánh giá khách hàng
   ========================================================================== */
.testimonial-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: var(--space-xl);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  border: 1px solid var(--color-border-soft);
  box-shadow: var(--shadow-sm);
  transition: transform var(--t-base), box-shadow var(--t-base);
}
.testimonial-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}
.testimonial-card__mark {
  position: absolute;
  top: var(--space-lg);
  right: var(--space-lg);
  width: 30px; height: 30px;
  color: var(--color-accent);
}
.testimonial-card blockquote {
  position: relative;     /* chữ nằm trên dấu ngoặc trang trí, không bị che */
  flex: 1;
  margin-bottom: var(--space-lg);
}
.testimonial-card blockquote p { color: var(--color-text-soft); }

.testimonial-card__author {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding-top: var(--space-md);
  border-top: 1px solid var(--color-border-soft);
}
/* Avatar dạng chữ cái đầu — không cần ảnh, luôn sắc nét */
.avatar {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 52px; height: 52px;
  border-radius: var(--radius-circle);
  background: var(--gradient-primary);
  color: var(--color-white);
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  letter-spacing: 0.03em;
  border: 2px solid var(--color-secondary-light);
}
.testimonial-card__author strong {
  display: block;
  font-size: var(--fs-base);
  color: var(--color-heading);
}
/* Chỉ áp cho dòng chữ phụ — nếu áp cho mọi <span> thì .avatar và .rating
   (độ đặc hiệu thấp hơn) bị ghi đè, làm avatar mất căn giữa và sao xếp dọc. */
.testimonial-card__author span:not(.avatar):not(.rating) {
  display: block;
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}


/* ==========================================================================
   18. FAQ — dùng thẻ <details> gốc của HTML, không cần JavaScript
   ========================================================================== */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.faq-item {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-white);
  overflow: hidden;
  transition: border-color var(--t-base), box-shadow var(--t-base);
}
.faq-item[open] {
  border-color: var(--color-secondary);
  box-shadow: var(--shadow-md);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-lg);
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  color: var(--color-heading);
  cursor: pointer;
  list-style: none;
  transition: color var(--t-fast);
}
/* Ẩn mũi tên mặc định của trình duyệt */
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::marker { content: ''; }
.faq-item summary:hover,
.faq-item[open] summary { color: var(--color-primary); }

/* Dấu cộng tự vẽ bằng CSS, xoay 45° thành dấu X khi mở */
.faq-item__icon {
  position: relative;
  flex-shrink: 0;
  width: 30px; height: 30px;
  border-radius: var(--radius-circle);
  background: var(--color-accent);
  transition: transform var(--t-base), background-color var(--t-base);
}
.faq-item__icon::before,
.faq-item__icon::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 12px; height: 2px;
  border-radius: var(--radius-pill);
  background: var(--color-primary);
  transform: translate(-50%, -50%);
  transition: background-color var(--t-base);
}
.faq-item__icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq-item[open] .faq-item__icon {
  transform: rotate(135deg);
  background: var(--color-primary);
}
.faq-item[open] .faq-item__icon::before,
.faq-item[open] .faq-item__icon::after { background: var(--color-white); }

.faq-item__content {
  padding: 0 var(--space-lg) var(--space-lg);
  color: var(--color-text-soft);
  animation: faq-open .3s var(--ease-out);
}
/* Câu trả lời dạng các bước: <p> dẫn + <ol class="faq-steps"> + <p> kết.
   Số thứ tự trong chấm tròn màu thương hiệu, chữ thụt đều sau số. */
.faq-item__content p + .faq-steps { margin-top: var(--space-sm); }
.faq-steps + p { margin-top: var(--space-sm); }
.faq-steps {
  display: grid;
  gap: var(--space-xs);
  counter-reset: faq-step;
}
.faq-steps li {
  position: relative;
  padding-left: 2.25rem;
  counter-increment: faq-step;
}
.faq-steps li::before {
  content: counter(faq-step);
  position: absolute;
  left: 0; top: .15em;
  display: grid;
  place-items: center;
  width: 1.5rem; height: 1.5rem;
  border-radius: var(--radius-circle);
  background: var(--color-accent);
  color: var(--color-primary);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  line-height: 1;
}

@keyframes faq-open {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* ==========================================================================
   19. CONTACT — trang liên hệ
   ========================================================================== */
.contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  height: 100%;
  padding: var(--space-xl) var(--space-lg);
  text-align: center;
  border-radius: var(--radius-lg);
  background: var(--color-white);
  border: 1px solid var(--color-border-soft);
  transition: transform var(--t-base), box-shadow var(--t-base), border-color var(--t-base);
}
.contact-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-secondary);
}
.contact-card__icon {
  display: grid;
  place-items: center;
  width: 56px; height: 56px;
  border-radius: var(--radius-circle);
  background: var(--color-accent);
  color: var(--color-primary);
  transition: background-color var(--t-base), color var(--t-base);
}
.contact-card__icon .icon { width: 25px; height: 25px; }
.contact-card:hover .contact-card__icon {
  background: var(--gradient-primary);
  color: var(--color-white);
}
.contact-card__title { font-size: var(--fs-h3); }
.contact-card p {
  font-size: var(--fs-sm);
  color: var(--color-text-soft);
}
.contact-card__value {
  font-size: var(--fs-base);
  font-weight: var(--fw-semibold);
  color: var(--color-primary);
  word-break: break-word;
}
.contact-card__value:hover { color: var(--color-primary-dark); }

/* Danh sách WhatsApp theo người phụ trách (contact.html) */
.wa-team-section { padding-bottom: 0; }   /* section kênh liên hệ ngay dưới đã có khoảng cách */
.wa-team {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-md);
}
.wa-team__item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg) var(--space-md) var(--space-md);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  transition: transform var(--t-base), box-shadow var(--t-base), border-color var(--t-base);
}
.wa-team__item:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-primary);
}
.wa-team__item:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 3px; }
.wa-team__avatar {
  flex-shrink: 0;
  width: 56px; height: 56px;
  border-radius: var(--radius-circle);
  border: 1px solid var(--color-border);
  background: var(--color-white);
  object-fit: cover;
}
.wa-team__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}
.wa-team__name {
  font-size: var(--fs-lg);
  font-weight: var(--fw-bold);
  color: var(--color-heading);
}
.wa-team__phone {
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: var(--color-primary);
  white-space: nowrap;
}
.wa-team__icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 44px; height: 44px;
  border-radius: var(--radius-circle);
  background: var(--color-primary);
  color: var(--color-white);
  transition: background-color var(--t-base);
}
.wa-team__icon .icon { width: 22px; height: 22px; }
.wa-team__item:hover .wa-team__icon { background: var(--color-primary-dark); }

/* Bảng giờ mở cửa */
.hours {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-base);
}
.hours caption {
  padding-bottom: var(--space-sm);
  font-weight: var(--fw-semibold);
  color: var(--color-heading);
  text-align: left;
}
.hours th,
.hours td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--color-border-soft);
}
.hours th {
  white-space: nowrap;           /* "Thứ 2 – Thứ 7" không ngắt dòng trên điện thoại */
  font-weight: var(--fw-medium);
  color: var(--color-text-soft);
}
.hours td {
  color: var(--color-heading);
  font-weight: var(--fw-medium);
  text-align: right;
}
.hours tr:last-child th,
.hours tr:last-child td { border-bottom: 0; }


/* ==========================================================================
   20. CTA CUỐI TRANG
   ========================================================================== */


/* ==========================================================================
   21. FOOTER
   ========================================================================== */
.footer {
  background: var(--color-dark);
  color: rgba(255, 255, 255, .7);
  font-size: var(--fs-sm);
}
.footer__top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  padding-block: clamp(3rem, 6vw, 4.5rem);
}

.logo--footer { margin-bottom: var(--space-md); }

.footer__about {
  max-width: 42ch;
  margin-bottom: var(--space-lg);
}
.footer__title {
  font-size: var(--fs-base);
  font-weight: var(--fw-bold);
  color: var(--color-white);
  margin-bottom: var(--space-md);
}
.footer__list {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}
.footer__list a:hover { color: var(--color-secondary); }
.footer__list--contact li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-xs);
}
.footer__list--contact .icon {
  margin-top: 4px;
  color: var(--color-secondary);
}

.footer__social {
  display: flex;
  gap: var(--space-xs);
}
.footer__social a {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: var(--radius-circle);
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(255, 255, 255, .12);
  color: var(--color-white);
  transition: background-color var(--t-base), transform var(--t-base), border-color var(--t-base);
}
.footer__social a:hover {
  background: var(--color-primary);
  border-color: var(--color-primary);
  transform: translateY(-3px);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding-block: var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: var(--fs-xs);
}
.footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-lg);
}
.footer__legal a:hover { color: var(--color-secondary); }


/* ==========================================================================
   22. FLOATING BUTTONS
   ========================================================================== */
.floating {
  position: fixed;
  right: clamp(1rem, 2vw, 1.75rem);
  bottom: clamp(1rem, 2vw, 1.75rem);
  z-index: var(--z-floating);
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-end;
  gap: var(--space-sm);
}
.floating__btn {
  position: relative;
  display: grid;
  place-items: center;
  width: 56px; height: 56px;
  border-radius: var(--radius-circle);
  color: var(--color-white);
  box-shadow: var(--shadow-lg);
  transition: transform var(--t-base), background-color var(--t-base), opacity var(--t-base);
}
.floating__btn .icon { width: 26px; height: 26px; }
.floating__btn:hover { transform: scale(1.08); }

.floating__btn--wa { background: var(--color-wa); }
.floating__btn--wa::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: var(--radius-circle);
  background: var(--color-wa);
  animation: pulse-ring 2.4s var(--ease-out) infinite;
}
@keyframes pulse-ring {
  0%   { transform: scale(1);   opacity: .55; }
  70%  { transform: scale(1.6); opacity: 0; }
  100% { transform: scale(1.6); opacity: 0; }
}

.floating__tip {
  position: absolute;
  right: calc(100% + 12px);
  white-space: nowrap;
  padding: 7px 14px;
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  color: var(--color-white);
  background: var(--color-dark);
  border-radius: var(--radius-pill);
  opacity: 0;
  transform: translateX(8px);
  pointer-events: none;
  transition: opacity var(--t-base), transform var(--t-base);
}
.floating__btn:hover .floating__tip,
.floating__btn:focus-visible .floating__tip {
  opacity: 1;
  transform: translateX(0);
}

/* Nút Instagram — giữa cụm (dưới: WhatsApp, trên: về đầu trang). */
.floating__btn--ig {
  width: 48px; height: 48px;
  background: var(--gradient-ig);      /* gradient gốc Instagram (27/09/2026) — dễ nhận diện */
}
.floating__btn--ig .icon { width: 22px; height: 22px; }
.floating__btn--ig:hover { filter: brightness(1.08); }

/* Nút về đầu trang — mặc định ẩn, JS hiện khi cuộn đủ xa */
.floating__btn--top {
  width: 48px; height: 48px;
  background: var(--color-primary);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
}
.floating__btn--top .icon { width: 21px; height: 21px; }
.floating__btn--top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.floating__btn--top:hover { background: var(--color-primary-dark); }


/* ==========================================================================
   23. MODAL — xem ảnh lớn  (video dùng 23b. REEL FEED)
   Mở bằng JS. Không có JS: link trong thẻ ảnh/video mở thẳng file gốc,
   nên chức năng vẫn dùng được bình thường.
   ========================================================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  display: grid;
  place-items: center;
  padding: var(--space-lg);
  opacity: 0;
  transition: opacity var(--t-base);
}
.modal[hidden] { display: none; }
.modal.is-open { opacity: 1; }

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 16, 12, .92);
  cursor: zoom-out;
}

.modal__dialog {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-md);
  width: 100%;
  max-width: 1000px;
  transform: scale(.96);
  transition: transform var(--t-base);
}
.modal.is-open .modal__dialog { transform: scale(1); }

.modal__figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  max-width: 100%;
}
.modal__figure img {
  max-height: 66vh;
  width: auto;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  object-fit: contain;
}
.modal__caption {
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: rgba(255, 255, 255, .85);
  text-align: center;
}

.modal__close {
  position: absolute;
  top: -10px; right: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  border-radius: var(--radius-circle);
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .28);
  color: var(--color-white);
  transition: background-color var(--t-base), transform var(--t-base);
}
.modal__close:hover {
  background: rgba(255, 255, 255, .28);
  transform: rotate(90deg);
}

.modal__nav {
  position: absolute;
  top: 42%;
  display: grid;
  place-items: center;
  width: 48px; height: 48px;
  border-radius: var(--radius-circle);
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .28);
  color: var(--color-white);
  transition: background-color var(--t-base), transform var(--t-base);
}
.modal__nav:hover { background: rgba(255, 255, 255, .3); }
.modal__nav--prev { left: -8px; }
.modal__nav--next { right: -8px; }


/* ==========================================================================
   23b. REEL FEED — xem video toàn màn hình, cuộn dọc kiểu TikTok/Reels
   Khung do js/slider.js (ReelFeed) tự tạo khi bấm thẻ [data-modal="video"].
   Mỗi video chiếm trọn một màn hình; scroll-snap giữ cho mỗi lần vuốt
   dừng đúng ở một video.
   ========================================================================== */
.reel-feed {
  position: fixed;
  inset: 0;
  z-index: var(--z-modal);
  background: var(--color-dark);
  color: var(--color-white);
}
.reel-feed[hidden] { display: none; }

.reel-feed__track {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  scroll-snap-type: y mandatory;
  scrollbar-width: none;
}
.reel-feed__track::-webkit-scrollbar { display: none; }

.reel-feed__item {
  position: relative;
  display: grid;
  place-items: center;
  height: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  cursor: pointer;
}
.reel-feed__video {
  width: 100%;
  height: 100%;
  max-width: calc(100vh * 9 / 16);   /* desktop: khung dọc 9:16 ở giữa màn hình */
  object-fit: contain;
  background: var(--color-dark);
}

/* Biểu tượng "đang tạm dừng" ở giữa video */
.reel-feed__paused {
  position: absolute;
  display: grid;
  place-items: center;
  width: 76px; height: 76px;
  border-radius: var(--radius-circle);
  background: rgba(30, 13, 11, .55);
  opacity: 0;
  transform: scale(.85);
  transition: opacity var(--t-base), transform var(--t-base);
  pointer-events: none;
}
.reel-feed__paused .icon { width: 34px; height: 34px; margin-left: 4px; }
.reel-feed__item.is-paused .reel-feed__paused { opacity: 1; transform: scale(1); }

.reel-feed__caption {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 100%;
  max-width: calc(100vh * 9 / 16);
  transform: translateX(-50%);
  padding: var(--space-3xl) var(--space-lg) calc(var(--space-xl) + env(safe-area-inset-bottom, 0px));
  background: var(--gradient-overlay);
  font-size: var(--fs-md);
  font-weight: var(--fw-semibold);
  pointer-events: none;
}

/* Thanh trên cùng: số thứ tự + nút loa + nút đóng */
.reel-feed__bar {
  position: absolute;
  top: calc(var(--space-md) + env(safe-area-inset-top, 0px));
  right: var(--space-md);
  left: var(--space-md);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-sm);
  pointer-events: none;
}
.reel-feed__count {
  margin-right: auto;
  padding: var(--space-2xs) var(--space-sm);
  border-radius: var(--radius-pill);
  background: rgba(30, 13, 11, .55);
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
}
.reel-feed__btn {
  display: grid;
  place-items: center;
  width: 48px; height: 48px;
  border-radius: var(--radius-circle);
  background: rgba(30, 13, 11, .55);
  border: 1px solid rgba(255, 255, 255, .28);
  color: var(--color-white);
  pointer-events: auto;
  transition: background-color var(--t-base), opacity var(--t-base);
}
.reel-feed__btn .icon { width: 22px; height: 22px; }
.reel-feed__btn:hover { background: var(--color-primary); }
.reel-feed__btn:focus-visible { outline: 2px solid var(--color-white); outline-offset: 3px; }
.reel-feed__btn:disabled { opacity: .3; cursor: default; }
.reel-feed__btn:disabled:hover { background: rgba(30, 13, 11, .55); }
.reel-feed__btn[aria-pressed="true"] { background: var(--color-primary); }

/* Nút lên/xuống bên phải — chỉ cần trên desktop, mobile vuốt tay */
.reel-feed__nav {
  position: absolute;
  right: var(--space-lg);
  top: 50%;
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  transform: translateY(-50%);
}

/* Hint hướng dẫn vuốt — icon bàn tay vuốt lên, mờ, ở CHÍNH GIỮA màn hình, không chữ.
   Chỉ ở video đầu tiên mỗi lần mở feed (class .show-hint do ReelFeed gắn/gỡ).
   Không bắt sự kiện chạm để không cản vuốt. */
.reel-feed__hint {
  position: absolute;
  top: 50%; left: 50%;
  width: 88px;
  color: var(--color-white);
  filter: drop-shadow(0 2px 6px rgba(30, 13, 11, .75));
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, -50%);
  transition: opacity var(--t-base), visibility var(--t-base);
  pointer-events: none;
}
.reel-feed.show-hint .reel-feed__hint { opacity: .65; visibility: visible; }
.reel-feed__hint-icon { display: block; width: 100%; height: auto; overflow: visible; }
/* Bàn tay trượt từ dưới lên (đúng hướng vuốt) rồi mờ đi, lặp lại */
.reel-feed__hint-hand { animation: reel-hint-swipe 1.8s var(--ease-out) infinite; }
.reel-feed__hint-arrow { animation: reel-hint-arrow 1.8s ease-in-out infinite; }
@keyframes reel-hint-swipe {
  0%   { transform: translateY(6px);  opacity: 0; }
  20%  { opacity: 1; }
  70%  { transform: translateY(-4px); opacity: 1; }
  100% { transform: translateY(-6px); opacity: 0; }
}
@keyframes reel-hint-arrow {
  0%, 40% { opacity: .3; }
  70%     { opacity: 1; }
  100%    { opacity: .3; }
}
/* Tắt chuyển động: bàn tay đứng yên, vẫn nhìn thấy */
@media (prefers-reduced-motion: reduce) {
  .reel-feed__hint-hand,
  .reel-feed__hint-arrow { animation: none; }
}


/* ==========================================================================
   24. SCROLL REVEAL
   HTML gắn data-reveal="fade-up | fade-left | fade-right".
   QUAN TRỌNG: phần tử chỉ bị ẩn khi JS đã chạy và gắn class .js vào <html>.
   Nhờ vậy nếu JS lỗi hoặc bị tắt, nội dung vẫn hiện đầy đủ.
   ========================================================================== */
.js [data-reveal] {
  opacity: 0;
  transition: opacity .7s var(--ease-out), transform .7s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}
.js [data-reveal="fade-up"]    { transform: translate3d(0, 30px, 0); }
.js [data-reveal="fade-left"]  { transform: translate3d(34px, 0, 0); }
.js [data-reveal="fade-right"] { transform: translate3d(-34px, 0, 0); }

.js [data-reveal].is-revealed {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}


/* ==========================================================================
   25. ACCESSIBILITY & MOTION PREFERENCES
   ========================================================================== */
:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}
.footer :focus-visible,
.modal :focus-visible,
.hero-slider :focus-visible {
  outline-color: var(--color-secondary-light);
}

/* Tôn trọng thiết lập giảm chuyển động của hệ điều hành */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }

  .js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }
}

@media (prefers-contrast: more) {
  :root {
    --color-text: #1E0D0B;
    --color-text-soft: #3A2A27;
    --color-border: #C9B2AE;
  }
}

@media print {
  .header, .floating, .modal, .carousel__btn, .breadcrumb { display: none !important; }
  body { color: #000; background: #fff; }
  .js [data-reveal] { opacity: 1 !important; transform: none !important; }
  .carousel__track { overflow: visible; flex-wrap: wrap; }
}
