/* ==========================================================================
   AURIX DESIGN SYSTEM
   Navy sâu · Gold khắc · Amber tia lửa
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  /* Nền — dải navy sâu dần */
  --ink-900: #070C15;
  --ink-800: #0B1220;
  --ink-700: #0F1829;
  --ink-600: #141F35;
  --ink-500: #1B2A45;
  --ink-400: #26385A;

  /* Gold — dấu ấn thương hiệu */
  --gold-400: #F0D9A0;
  --gold-300: #E8C468;
  --gold-200: #D4AF37;
  --gold-100: #B8861F;
  --gold-grad: linear-gradient(135deg, #F0D9A0 0%, #D4AF37 45%, #B8861F 100%);

  /* Amber — tia lửa, chỉ dùng làm điểm nhấn nhỏ */
  --amber: #FF9F2E;
  --amber-soft: rgba(255, 159, 46, 0.16);

  /* Chữ */
  --fg: #F4F6FA;
  --fg-soft: #AEB9CC;
  --fg-mute: #7E8CA3;

  /* Đường & bề mặt */
  --line: rgba(212, 175, 55, 0.18);
  --line-soft: rgba(244, 246, 250, 0.09);
  --surface: rgba(255, 255, 255, 0.028);
  --surface-2: rgba(255, 255, 255, 0.05);

  /* Chữ nghệ thuật */
  --font-display: 'Be Vietnam Pro', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Be Vietnam Pro', 'Segoe UI', system-ui, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;

  /* Nhịp */
  --sp: clamp(64px, 9vw, 132px);
  --gutter: clamp(20px, 5vw, 64px);
  --maxw: 1240px;
  --radius: 18px;
  --radius-sm: 12px;

  /* Chuyển động */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --dur: 0.6s;

  --shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.7);
  --shadow-gold: 0 20px 60px -18px rgba(212, 175, 55, 0.35);
}

/* ---------- 2. Nền tảng ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ink-800);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.72;
  font-weight: 400;
  letter-spacing: -0.003em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* Lớp nền cố định: vignette + lưới vàng mảnh */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(120% 80% at 50% -10%, #16243D 0%, transparent 60%),
    radial-gradient(90% 60% at 88% 8%, rgba(212, 175, 55, 0.10) 0%, transparent 55%),
    var(--ink-800);
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(212, 175, 55, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(212, 175, 55, 0.035) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(120% 70% at 50% 0%, #000 0%, transparent 72%);
  mask-image: radial-gradient(120% 70% at 50% 0%, #000 0%, transparent 72%);
}

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

/* Thuộc tính hidden phải luôn thắng. Quy tắc [hidden] mặc định của trình duyệt
   nằm ở tầng user-agent nên bất kỳ khai báo display nào của ta cũng đè lên nó —
   ví dụ .proj { display: block } sẽ khiến thẻ đã ẩn vẫn hiện. */
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

::selection { background: var(--gold-200); color: var(--ink-900); }

:focus-visible {
  outline: 2px solid var(--gold-300);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- 3. Chữ ---------- */
h1, h2, h3, h4, h5 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.14;
  letter-spacing: -0.028em;
  text-wrap: balance;
}

h1 { font-size: clamp(38px, 6.4vw, 76px); font-weight: 800; letter-spacing: -0.04em; }
h2 { font-size: clamp(30px, 4.2vw, 50px); }
h3 { font-size: clamp(21px, 2.3vw, 28px); }
h4 { font-size: clamp(18px, 1.7vw, 21px); }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

.lead {
  font-size: clamp(17px, 1.9vw, 21px);
  line-height: 1.68;
  color: var(--fg-soft);
  font-weight: 400;
  max-width: 62ch;
  text-wrap: pretty;
}

.muted { color: var(--fg-mute); }
.soft { color: var(--fg-soft); }
.serif { font-family: var(--font-serif); font-weight: 500; }

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

.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;
}

/* ---------- 4. Bố cục ---------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap-narrow { max-width: 880px; }

section { position: relative; padding-block: var(--sp); }

.grid { display: grid; gap: clamp(20px, 2.6vw, 32px); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

@media (max-width: 960px) {
  .g-3, .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .g-2, .g-3, .g-4 { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- 5. Nhãn tiêu đề mục (dấu ấn thương hiệu) ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-300);
  margin-bottom: 22px;
}

.eyebrow::before {
  content: '';
  width: 26px;
  height: 1px;
  background: var(--gold-grad);
  flex: none;
}

/* Tia lửa chữ A — motif lặp lại toàn site */
.spark {
  display: inline-block;
  width: 13px;
  height: 13px;
  flex: none;
  background: var(--gold-grad);
  -webkit-mask: var(--spark-mask) center/contain no-repeat;
  mask: var(--spark-mask) center/contain no-repeat;
  --spark-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M13.6 1 3 14.2h6.2L8.1 23 19 9.6h-6.4L13.6 1Z'/%3E%3C/svg%3E");
}

.section-head { max-width: 760px; margin-bottom: clamp(40px, 5vw, 64px); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .eyebrow::before { display: none; }
.section-head h2 + .lead { margin-top: 20px; }

/* ---------- 6. Nút ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 30px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease), color 0.35s var(--ease);
  will-change: transform;
}

.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--gold-grad);
  color: var(--ink-900);
  box-shadow: var(--shadow-gold);
}

/* Vệt sáng quét qua nút */
.btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(100deg, transparent 20%, rgba(255, 255, 255, 0.65) 50%, transparent 80%);
  transform: translateX(-120%);
  transition: transform 0.8s var(--ease);
}
.btn-primary:hover::after { transform: translateX(120%); }

.btn-ghost {
  background: var(--surface);
  border-color: var(--line);
  color: var(--fg);
  backdrop-filter: blur(12px);
}
.btn-ghost:hover { border-color: var(--gold-200); background: var(--surface-2); }

.btn-lg { padding: 19px 38px; font-size: 16px; }
.btn-sm { padding: 11px 20px; font-size: 14px; }

.btn .arrow { transition: transform 0.35s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* Liên kết dạng mũi tên */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 15px;
  color: var(--gold-300);
  transition: gap 0.3s var(--ease);
}
.link-arrow:hover { gap: 13px; }

/* ---------- 7. Thẻ ---------- */
.card {
  position: relative;
  padding: clamp(26px, 3vw, 36px);
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
  background: var(--surface);
  overflow: hidden;
  isolation: isolate;
  transition: border-color 0.5s var(--ease), transform 0.5s var(--ease), background 0.5s var(--ease);
}

.card:hover {
  border-color: var(--line);
  background: var(--surface-2);
  transform: translateY(-4px);
}

/* Hào quang vàng theo con trỏ */
.card::before {
  content: '';
  position: absolute;
  inset: -1px;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.5s var(--ease);
  background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(212, 175, 55, 0.14), transparent 65%);
}
.card:hover::before { opacity: 1; }

.card h3 { margin-bottom: 12px; }
.card p { color: var(--fg-soft); font-size: 16px; }

/* ---------- 8. Hiệu ứng xuất hiện ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: var(--delay, 0ms);
}
[data-reveal].is-in { opacity: 1; transform: none; }

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