/**
 * XuanHieu V2.1 — Master craft pass
 * Cinematic Authority · optical hierarchy · zero broken first paint
 * Designer notes: glass nav, portrait as art, bento with presence, human proof
 */

:root {
  --xh-bg: #06080f;
  --xh-bg-2: #0c1220;
  --xh-bg-3: #151d30;
  --xh-elev: rgba(255, 255, 255, 0.045);
  --xh-elev-2: rgba(255, 255, 255, 0.07);
  --xh-text: #f4f1ea;
  --xh-muted: rgba(244, 241, 234, 0.72);
  --xh-dim: rgba(244, 241, 234, 0.62); /* AA contrast on dark cards */
  --xh-line: rgba(255, 255, 255, 0.09);
  --xh-line-strong: rgba(255, 255, 255, 0.16);
  --xh-amber: #f0b429;
  --xh-amber-2: #ffc857;
  --xh-amber-soft: rgba(240, 180, 41, 0.14);
  --xh-blue: rgba(88, 140, 255, 0.18);
  --xh-max: 1120px;
  /* System stack = zero web-font CLS (lab CLS was 0.355 from FOIT/FOUT). */
  --xh-font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", "Be Vietnam Pro", Arial, sans-serif;
  --xh-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --xh-r: 16px;
  --xh-r-lg: 24px;
  --xh-r-xl: 32px;
  --xh-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
  --xh-shadow-glow: 0 0 80px rgba(240, 180, 41, 0.12);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  [data-xh-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }
}

body.xh-home-v2 {
  margin: 0;
  min-height: 100vh;
  background: var(--xh-bg);
  color: var(--xh-text);
  font-family: var(--xh-font);
  font-size: 16.5px;
  line-height: 1.65;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

body.xh-home-v2 ::selection {
  background: var(--xh-amber-soft);
  color: var(--xh-text);
}

body.xh-home-v2 a {
  color: var(--xh-amber);
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

body.xh-home-v2 a:focus-visible,
body.xh-home-v2 .v2-btn:focus-visible {
  outline: 2px solid var(--xh-amber);
  outline-offset: 3px;
}

/* —— Atmosphere —— */
.v2-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(1100px 620px at 8% -8%, rgba(240, 180, 41, 0.14), transparent 58%),
    radial-gradient(900px 560px at 92% 8%, var(--xh-blue), transparent 52%),
    radial-gradient(700px 480px at 50% 110%, rgba(240, 180, 41, 0.05), transparent 50%),
    var(--xh-bg);
}
.v2-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
  opacity: 0.04;
  mix-blend-mode: overlay;
}
.v2-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(6, 8, 15, 0.2) 100%);
}

.v2-wrap {
  width: min(100% - 2.25rem, var(--xh-max));
  margin-inline: auto;
}

/* —— Floating glass nav —— */
.v2-nav-shell {
  position: sticky;
  top: 0;
  z-index: 60;
  padding: 0.85rem 0 0;
}
html.xh-scrolled .v2-nav-shell {
  padding-top: 0.55rem;
}
.v2-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.55rem 0.55rem 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  transition: background 0.35s var(--xh-ease), border-color 0.35s, box-shadow 0.35s, backdrop-filter 0.35s;
}
html.xh-scrolled .v2-nav {
  background: rgba(10, 14, 24, 0.72);
  border-color: var(--xh-line);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}
.v2-nav__brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}
.v2-nav__mark {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #0a0c12;
  background: linear-gradient(145deg, var(--xh-amber-2), var(--xh-amber));
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 8px 20px rgba(240, 180, 41, 0.25);
  flex-shrink: 0;
}
.v2-nav__text {
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
  min-width: 0;
  line-height: 1.15;
}
.v2-nav__name {
  display: block;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.v2-nav__sub {
  display: block;
  font-size: 0.68rem;
  color: var(--xh-dim);
  letter-spacing: 0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.v2-nav__links {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}
.v2-nav__links a:not(.v2-btn) {
  color: var(--xh-muted);
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 500;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  transition: color 0.2s, background 0.2s;
}
.v2-nav__links a:not(.v2-btn):hover {
  color: var(--xh-text);
  background: var(--xh-elev);
}

/* —— Buttons —— */
.v2-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.8rem 1.3rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 650;
  letter-spacing: -0.015em;
  text-decoration: none !important;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.2s var(--xh-ease), background 0.2s, border-color 0.2s, box-shadow 0.25s, color 0.2s;
  white-space: nowrap;
}
.v2-btn:active {
  transform: translateY(1px) scale(0.99);
}
.v2-btn--amber {
  background: linear-gradient(180deg, var(--xh-amber-2), var(--xh-amber));
  color: #0a0c12 !important;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.25) inset, 0 10px 28px rgba(240, 180, 41, 0.28);
}
.v2-btn--amber:hover {
  filter: brightness(1.05);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.3) inset, 0 14px 36px rgba(240, 180, 41, 0.38);
  color: #0a0c12 !important;
}
.v2-btn--ghost {
  background: var(--xh-elev);
  color: var(--xh-text) !important;
  border-color: var(--xh-line-strong);
}
.v2-btn--ghost:hover {
  border-color: rgba(240, 180, 41, 0.45);
  background: var(--xh-amber-soft);
  color: var(--xh-text) !important;
}
.v2-btn--sm {
  padding: 0.52rem 1rem;
  font-size: 0.82rem;
}

/* —— Hero —— */
.v2-hero {
  padding: clamp(1.75rem, 4.5vw, 3.25rem) 0 clamp(2.5rem, 6vw, 4rem);
  min-height: min(88svh, 640px);
}
.v2-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(280px, 0.88fr);
  gap: clamp(1.75rem, 4vw, 3.25rem);
  align-items: center;
  min-height: 420px;
}
.v2-portrait__frame {
  contain: layout paint;
  max-width: 420px;
  margin-left: auto;
  width: 100%;
}
@media (max-width: 900px) {
  .v2-hero {
    min-height: 0;
    padding-top: 1.25rem;
  }
  .v2-hero__grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    min-height: 0;
  }
  .v2-hero__visual {
    order: -1;
    max-width: min(72vw, 300px);
    margin: 0 auto;
  }
  .v2-portrait__frame {
    max-width: none;
    margin-inline: auto;
  }
  .v2-nav__links a:not(.v2-btn) {
    display: none;
  }
  .v2-nav__sub {
    display: none;
  }
  .v2-nav {
    padding-left: 0.65rem;
  }
}
.v2-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--xh-amber);
  margin: 0 0 0.95rem;
}
.v2-kicker::before {
  content: "";
  width: 1.35rem;
  height: 2px;
  border-radius: 2px;
  background: var(--xh-amber);
  box-shadow: 0 0 12px var(--xh-amber);
}
.v2-hero h1 {
  margin: 0 0 0.55rem;
  font-size: clamp(2.45rem, 6.2vw, 4.15rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.02;
  color: var(--xh-text);
  text-wrap: balance;
}
.v2-hero__role {
  margin: 0 0 1.05rem;
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  font-weight: 550;
  color: var(--xh-amber);
  letter-spacing: -0.02em;
}
.v2-hero__sub {
  margin: 0 0 1.5rem;
  max-width: 34rem;
  font-size: 1.02rem;
  line-height: 1.72;
  color: var(--xh-muted);
  text-wrap: pretty;
}
.v2-hero__sub strong {
  color: var(--xh-text);
  font-weight: 600;
}
.v2-hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}
.v2-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.v2-metrics li {
  font-size: 0.78rem;
  color: var(--xh-muted);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--xh-line);
  background: var(--xh-elev);
}
.v2-metrics li strong {
  color: var(--xh-text);
  font-weight: 650;
}

/* Portrait art */
.v2-portrait {
  position: relative;
  isolation: isolate;
}
.v2-portrait__ring {
  position: absolute;
  inset: -14%;
  border-radius: 42% 58% 52% 48% / 48% 42% 58% 52%;
  background: conic-gradient(
    from 200deg,
    rgba(240, 180, 41, 0.45),
    transparent 32%,
    rgba(88, 140, 255, 0.35),
    transparent 68%,
    rgba(240, 180, 41, 0.4)
  );
  filter: blur(32px);
  opacity: 0.9;
  z-index: 0;
  animation: v2-spin 22s linear infinite;
}
@keyframes v2-spin {
  to {
    transform: rotate(360deg);
  }
}
.v2-portrait__frame {
  position: relative;
  z-index: 1;
  border-radius: var(--xh-r-xl);
  overflow: hidden;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: var(--xh-bg-2);
  box-shadow: var(--xh-shadow), var(--xh-shadow-glow), 0 0 0 1px rgba(240, 180, 41, 0.15);
}
.v2-portrait__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  display: block;
  filter: contrast(1.04) saturate(1.06);
}
.v2-portrait__frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(185deg, transparent 42%, rgba(6, 8, 15, 0.82) 100%);
  pointer-events: none;
}
.v2-portrait__cap {
  position: absolute;
  left: 1.15rem;
  right: 1.15rem;
  bottom: 1.05rem;
  z-index: 2;
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  color: rgba(244, 241, 234, 0.92);
  font-weight: 500;
}

/* —— Sections —— */
.v2-section {
  padding: clamp(2.75rem, 6vw, 4.75rem) 0;
  position: relative;
}
.v2-section--tight {
  padding-top: 0.5rem;
}
.v2-section__head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.6rem;
}
.v2-h2 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.55rem, 2.8vw, 2rem);
  font-weight: 750;
  letter-spacing: -0.035em;
  line-height: 1.15;
  text-wrap: balance;
}
.v2-lede {
  margin: 0;
  max-width: 34rem;
  color: var(--xh-muted);
  font-size: 0.98rem;
  line-height: 1.65;
}
.v2-link {
  color: var(--xh-amber) !important;
  font-weight: 600;
  font-size: 0.88rem;
  text-decoration: none !important;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}
.v2-link:hover {
  color: var(--xh-amber-2) !important;
}

/* Proof — human chips */
.v2-proof {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.75rem;
}
@media (max-width: 860px) {
  .v2-proof {
    grid-template-columns: repeat(2, 1fr);
  }
}
.v2-proof__item {
  position: relative;
  padding: 1.2rem 1.1rem 1.15rem;
  border-radius: var(--xh-r);
  background: var(--xh-elev);
  border: 1px solid var(--xh-line);
  overflow: hidden;
  transition: border-color 0.25s, transform 0.3s var(--xh-ease), background 0.25s;
}
.v2-proof__item:hover {
  border-color: rgba(240, 180, 41, 0.28);
  background: var(--xh-elev-2);
  transform: translateY(-2px);
}
.v2-proof__item::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(240, 180, 41, 0.45), transparent);
  opacity: 0.7;
}
.v2-proof__num {
  display: block;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--xh-amber);
  margin-bottom: 0.35rem;
  line-height: 1;
}
.v2-proof__label {
  font-size: 0.84rem;
  color: var(--xh-muted);
  line-height: 1.45;
}

/* Bento with presence */
.v2-bento {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  grid-template-rows: repeat(3, minmax(118px, auto));
  gap: 0.85rem;
}
@media (max-width: 800px) {
  .v2-bento {
    grid-template-columns: 1fr;
    grid-template-rows: none;
  }
}
.v2-bento__card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 118px;
  padding: 1.35rem 1.3rem;
  border-radius: var(--xh-r-lg);
  text-decoration: none !important;
  color: inherit !important;
  border: 1px solid var(--xh-line);
  background: var(--xh-elev);
  overflow: hidden;
  transition: transform 0.35s var(--xh-ease), border-color 0.25s, box-shadow 0.35s, background 0.25s;
}
.v2-bento__card::before {
  content: attr(data-num);
  position: absolute;
  top: 0.85rem;
  right: 1rem;
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.06em;
  line-height: 1;
  color: rgba(255, 255, 255, 0.04);
  pointer-events: none;
  user-select: none;
}
.v2-bento__card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(420px 220px at 100% 0%, rgba(240, 180, 41, 0.12), transparent 60%);
  opacity: 0.85;
  pointer-events: none;
}
.v2-bento__card > * {
  position: relative;
  z-index: 1;
}
.v2-bento__card:hover {
  transform: translateY(-4px);
  border-color: rgba(240, 180, 41, 0.35);
  box-shadow: var(--xh-shadow);
  background: var(--xh-elev-2);
}
.v2-bento__card--lg {
  grid-row: span 3;
  min-height: 100%;
  padding: 1.75rem 1.6rem;
  background:
    radial-gradient(600px 340px at 85% 15%, rgba(240, 180, 41, 0.2), transparent 55%),
    radial-gradient(400px 280px at 10% 90%, rgba(88, 140, 255, 0.12), transparent 50%),
    var(--xh-elev);
}
.v2-bento__card--lg::before {
  font-size: clamp(4rem, 8vw, 6.5rem);
  top: 1rem;
  right: 1.1rem;
  color: rgba(255, 255, 255, 0.05);
}
@media (max-width: 800px) {
  .v2-bento__card--lg {
    grid-row: auto;
    min-height: 240px;
  }
}
.v2-bento__tag {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--xh-amber);
  margin-bottom: 0.45rem;
}
.v2-bento__title {
  margin: 0 0 0.4rem;
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
}
.v2-bento__card--lg .v2-bento__title {
  font-size: clamp(1.55rem, 2.6vw, 2rem);
}
.v2-bento__desc {
  margin: 0;
  color: var(--xh-muted);
  font-size: 0.92rem;
  line-height: 1.55;
  max-width: 28rem;
}
.v2-bento__go {
  margin-top: 0.95rem;
  font-size: 0.84rem;
  font-weight: 650;
  color: var(--xh-amber);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}
.v2-bento__card:hover .v2-bento__go {
  gap: 0.45rem;
}

/* Cards / mosaic */
.v2-mosaic {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: 0.85rem;
}
@media (max-width: 800px) {
  .v2-mosaic {
    grid-template-columns: 1fr;
  }
}
.v2-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--xh-r-lg);
  overflow: hidden;
  border: 1px solid var(--xh-line);
  background: var(--xh-elev);
  text-decoration: none !important;
  color: inherit !important;
  transition: transform 0.35s var(--xh-ease), border-color 0.25s, box-shadow 0.35s;
}
.v2-card:hover {
  transform: translateY(-3px);
  border-color: rgba(240, 180, 41, 0.3);
  box-shadow: var(--xh-shadow);
}
.v2-card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: linear-gradient(145deg, #1a2438, #0c1220 55%, #1a1520);
  overflow: hidden;
}
.v2-card__media--empty {
  display: grid;
  place-items: center;
}
.v2-card__media--empty::before {
  content: attr(data-letter);
  font-size: 3rem;
  font-weight: 800;
  letter-spacing: -0.06em;
  color: rgba(240, 180, 41, 0.35);
}
.v2-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.55s var(--xh-ease);
}
.v2-card:hover .v2-card__media img {
  transform: scale(1.045);
}
.v2-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(6, 8, 15, 0.35));
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s;
}
.v2-card:hover .v2-card__media::after {
  opacity: 1;
}
.v2-card__body {
  padding: 1.05rem 1.15rem 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  flex: 1;
}
.v2-chip {
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--xh-amber);
}
.v2-card__title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 650;
  letter-spacing: -0.022em;
  line-height: 1.32;
  text-wrap: balance;
}
.v2-card--hero .v2-card__title {
  font-size: clamp(1.18rem, 2vw, 1.42rem);
}
.v2-card__meta {
  margin-top: auto;
  padding-top: 0.5rem;
  font-size: 0.76rem;
  color: var(--xh-dim);
}
.v2-stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.v2-card--row {
  flex-direction: row;
  min-height: 118px;
}
.v2-card--row .v2-card__media {
  width: 40%;
  aspect-ratio: auto;
  min-height: 100%;
  flex-shrink: 0;
}
.v2-card--row .v2-card__body {
  width: 60%;
}
@media (max-width: 520px) {
  .v2-card--row {
    flex-direction: column;
  }
  .v2-card--row .v2-card__media,
  .v2-card--row .v2-card__body {
    width: 100%;
  }
  .v2-card--row .v2-card__media {
    aspect-ratio: 16 / 10;
  }
}

/* Services */
.v2-services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}
@media (max-width: 800px) {
  .v2-services {
    grid-template-columns: 1fr;
  }
}
.v2-svc {
  position: relative;
  padding: 1.5rem 1.35rem 1.4rem;
  border-radius: var(--xh-r-lg);
  border: 1px solid var(--xh-line);
  background: var(--xh-elev);
  overflow: hidden;
  transition: border-color 0.25s, transform 0.3s var(--xh-ease);
}
.v2-svc:hover {
  border-color: rgba(240, 180, 41, 0.28);
  transform: translateY(-2px);
}
.v2-svc__n {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: var(--xh-amber);
  margin-bottom: 0.7rem;
}
.v2-svc h3 {
  margin: 0 0 0.45rem;
  font-size: 1.12rem;
  letter-spacing: -0.025em;
  font-weight: 700;
}
.v2-svc p {
  margin: 0;
  color: var(--xh-muted);
  font-size: 0.92rem;
  line-height: 1.55;
}

/* Latest / multi-card grids */
.v2-latest {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
}
@media (max-width: 900px) {
  .v2-latest {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 520px) {
  .v2-latest {
    grid-template-columns: 1fr;
  }
}

/* Category directory — library show-off + internal links */
.v2-dir {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.65rem;
}
@media (max-width: 900px) {
  .v2-dir {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 420px) {
  .v2-dir {
    grid-template-columns: 1fr;
  }
}
.v2-dir__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.95rem 1.05rem;
  border-radius: var(--xh-r);
  border: 1px solid var(--xh-line);
  background: var(--xh-elev);
  text-decoration: none !important;
  color: inherit !important;
  transition: border-color 0.22s, transform 0.28s var(--xh-ease), background 0.22s;
  min-height: 3.4rem;
}
.v2-dir__item:hover {
  border-color: rgba(240, 180, 41, 0.35);
  background: var(--xh-elev-2);
  transform: translateY(-2px);
}
.v2-dir__name {
  font-weight: 650;
  font-size: 0.92rem;
  letter-spacing: -0.02em;
  line-height: 1.3;
}
.v2-dir__count {
  flex-shrink: 0;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.02em;
  color: var(--xh-amber);
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(240, 180, 41, 0.25);
  background: var(--xh-amber-soft);
}
.v2-hubs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.15rem;
}
.v2-hub {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 0.95rem;
  border-radius: 999px;
  border: 1px solid var(--xh-line-strong);
  background: transparent;
  color: var(--xh-muted) !important;
  text-decoration: none !important;
  font-size: 0.84rem;
  font-weight: 600;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.v2-hub:hover {
  color: var(--xh-text) !important;
  border-color: rgba(240, 180, 41, 0.4);
  background: var(--xh-amber-soft);
}

/* Band */
.v2-band {
  border-radius: var(--xh-r-xl);
  border: 1px solid rgba(240, 180, 41, 0.22);
  background:
    radial-gradient(520px 220px at 0% 50%, rgba(240, 180, 41, 0.14), transparent 60%),
    radial-gradient(420px 200px at 100% 50%, rgba(88, 140, 255, 0.1), transparent 55%),
    var(--xh-elev);
  padding: clamp(1.5rem, 3.5vw, 2.15rem) clamp(1.35rem, 3vw, 2rem);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.15rem;
  box-shadow: var(--xh-shadow-glow);
}

/* FAQ */
.v2-faq {
  display: grid;
  gap: 0.6rem;
  max-width: 46rem;
}
.v2-faq details {
  border: 1px solid var(--xh-line);
  border-radius: var(--xh-r);
  background: var(--xh-elev);
  padding: 0.95rem 1.2rem;
  transition: border-color 0.2s;
}
.v2-faq details[open] {
  border-color: rgba(240, 180, 41, 0.28);
}
.v2-faq summary {
  cursor: pointer;
  font-weight: 650;
  letter-spacing: -0.015em;
  list-style: none;
  color: var(--xh-text);
}
.v2-faq summary::-webkit-details-marker {
  display: none;
}
.v2-faq summary::after {
  content: "+";
  float: right;
  color: var(--xh-amber);
  font-weight: 500;
}
.v2-faq details[open] summary::after {
  content: "–";
}
.v2-faq details[open] summary {
  color: var(--xh-amber);
  margin-bottom: 0.5rem;
}
.v2-faq p {
  margin: 0;
  color: var(--xh-muted);
  font-size: 0.92rem;
  line-height: 1.65;
  clear: both;
}
.v2-faq a {
  color: var(--xh-amber);
}

/* Footer */
.v2-footer {
  padding: 2.75rem 0 3.25rem;
  border-top: 1px solid var(--xh-line);
  margin-top: 0.5rem;
}
.v2-footer__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1.5rem;
  align-items: start;
}
.v2-footer p {
  margin: 0.28rem 0;
  color: var(--xh-dim);
  font-size: 0.86rem;
}
.v2-footer a {
  color: var(--xh-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.v2-footer a:hover {
  color: var(--xh-amber);
}
.v2-footer__brand {
  color: var(--xh-text) !important;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem !important;
  font-size: 0.98rem !important;
}
.v2-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.15rem;
  font-size: 0.86rem;
}

/* Reveal disabled for CLS (PageSpeed layout-shift 0.35). Keep attribute for future. */
[data-xh-reveal] {
  opacity: 1;
  transform: none;
}
.v2-hero__visual,
.v2-nav-shell,
.v2-nav {
  opacity: 1 !important;
  transform: none !important;
}

/* Sticky nav always has solid glass base — prevent content bleed-through */
.v2-nav-shell {
  background: linear-gradient(180deg, rgba(6, 8, 15, 0.92) 40%, rgba(6, 8, 15, 0));
}
html.xh-scrolled .v2-nav-shell {
  background: transparent;
}
.v2-card__meta {
  color: rgba(244, 241, 234, 0.68) !important;
}

body.admin-bar .v2-nav-shell {
  top: 32px;
}
@media (max-width: 782px) {
  body.admin-bar .v2-nav-shell {
    top: 46px;
  }
}

/* deploy 2026-07-15 cachebust */
[data-xh-reveal]{opacity:1!important;transform:none!important}

/* —— Intent paths (V2.2) —— */
.v2-section__head--stack {
  margin-bottom: 1.1rem;
}
.v2-intent {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}
.v2-intent__item {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 1.15rem 1.2rem 1.2rem;
  border-radius: var(--xh-r);
  border: 1px solid var(--xh-line);
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
  text-decoration: none !important;
  color: inherit;
  min-height: 7.5rem;
  transition: border-color 0.2s, transform 0.2s var(--xh-ease), background 0.2s, box-shadow 0.25s;
}
.v2-intent__item:hover {
  border-color: rgba(240, 180, 41, 0.45);
  background: var(--xh-amber-soft);
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
}
.v2-intent__ico {
  font-size: 1.05rem;
  color: var(--xh-amber);
  line-height: 1;
  margin-bottom: 0.15rem;
}
.v2-intent__t {
  font-weight: 700;
  font-size: 1.02rem;
  letter-spacing: -0.025em;
  color: var(--xh-text);
  line-height: 1.25;
}
.v2-intent__d {
  font-size: 0.86rem;
  color: var(--xh-muted);
  line-height: 1.45;
}
@media (max-width: 900px) {
  .v2-intent {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 520px) {
  .v2-intent {
    grid-template-columns: 1fr;
  }
}
.v2-hero__cta .v2-btn--sm {
  align-self: center;
}
#doc-nhieu {
  scroll-margin-top: 5.5rem;
}

/* —— W4 polish (2026-07-15) —— */
.v2-card__media {
  position: relative;
}
.v2-card__badge {
  position: absolute;
  top: 0.65rem;
  left: 0.65rem;
  z-index: 3;
  padding: 0.28rem 0.6rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #0a0c12;
  background: linear-gradient(180deg, #ffc857, #f0b429);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
  pointer-events: none;
}
.v2-card--hot {
  border-color: rgba(240, 180, 41, 0.28);
}
.v2-card--hot:hover {
  border-color: rgba(240, 180, 41, 0.5);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(240, 180, 41, 0.12);
}
.v2-hero__cta {
  gap: 0.55rem;
}
@media (max-width: 520px) {
  .v2-hero__cta {
    flex-direction: column;
    align-items: stretch;
  }
  .v2-hero__cta .v2-btn {
    width: 100%;
  }
}
.v2-intent__item:focus-visible {
  outline: 2px solid var(--xh-amber);
  outline-offset: 2px;
}
.v2-section__head .v2-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
#doc-nhieu .v2-kicker::before {
  content: "";
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--xh-amber);
  box-shadow: 0 0 0 4px rgba(240, 180, 41, 0.2);
}
