/* ============================================================
   BASE — reset + nguyên tố dùng chung + nút + thẻ
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--ink-2);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; display: block; }

h1, h2, h3, h4 {
  margin: 0;
  color: var(--ink);
  line-height: var(--lh-tight);
  font-weight: 900;
  letter-spacing: -.02em;
}
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); font-weight: 800; }

p { margin: 0 0 var(--s-4); }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }

button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }

/* Vòng focus: dùng --ink chứ không dùng lime — lime trên nền trắng
   chỉ đạt 1.42:1, người dùng bàn phím sẽ không thấy vòng focus. */
:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
  border-radius: var(--r-sm);
}

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--s-6); }

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------------- Nút ---------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-2);
  height: var(--h-btn); padding-inline: var(--s-8);
  border-radius: var(--r-pill);
  font-weight: 800; font-size: var(--fs-body); letter-spacing: .01em;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t) var(--ease),
              background-color var(--t) var(--ease);
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(.995); }

/* Nút chính — gradient lime, CHỮ ĐEN (11.98:1 ở chặng tối nhất).
   Đúng như nút CONTINUE của bản gốc: nền lime sáng, chữ than. */
.btn--primary {
  background: linear-gradient(92deg, #E4FF66 0%, #D8FC3E 55%, #C2E724 100%);
  color: var(--ink);
  box-shadow: 0 8px 24px rgba(194,231,36,.45);
}
.btn--primary:hover { box-shadow: 0 12px 32px rgba(194,231,36,.58); }

/* Nút nhấn thương hiệu (lime) — dùng trong app */
.btn--lime { background: var(--lime); color: var(--ink); box-shadow: var(--sh-lime); }
.btn--lime:hover { background: var(--lime-deep); }

/* Nút viền */
.btn--ghost { background: transparent; color: var(--ink); border: 2px solid var(--lime-deep); }
.btn--ghost:hover { background: var(--lime-wash); }

/* Nút tối */
.btn--dark { background: var(--ink); color: var(--white); }

.btn--sm  { height: var(--h-btn-sm); padding-inline: var(--s-5); font-size: var(--fs-sm); }
.btn--full { width: 100%; }
/* Nút vô hiệu — xám khối bản gốc. 3.12:1: WCAG 1.4.3 miễn trừ
   điều khiển không hoạt động, xem ghi chú cuối tokens.css. */
.btn[disabled], .btn[aria-disabled="true"] {
  background: var(--gray-block); color: var(--ink-3); box-shadow: none; cursor: not-allowed;
}

.btn__arrow {
  width: 28px; height: 28px; border-radius: var(--r-pill);
  background: var(--ink); color: var(--white);
  display: grid; place-items: center; font-size: 14px;
}

/* ---------------- Thẻ ---------------- */

.card {
  background: var(--white);
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  padding: var(--s-6);
}
.card--flat { border: 0; box-shadow: var(--sh-md); }

/* ---------------- Nhãn ---------------- */

.pill {
  display: inline-flex; align-items: center; gap: var(--s-2);
  height: 28px; padding-inline: var(--s-3);
  border-radius: var(--r-pill);
  background: var(--lime-wash); color: var(--ink);
  font-size: var(--fs-xs); font-weight: 800;
}
.pill--dark { background: var(--ink); color: var(--lime); }
.pill--line { background: transparent; border: 1px solid var(--line); color: var(--ink-3); }

/* ---------------- Tiêu đề section ---------------- */

.sec { padding-block: var(--sec-pad); }
.sec--cream   { background: var(--cream); }
.sec--cream-2 { background: var(--cream-2); }

.sec-title { text-align: center; margin-bottom: var(--s-12); }
.sec-title h2 { font-size: var(--fs-h1); }
.sec-title .lead { color: var(--ink-3); max-width: 620px; margin: var(--s-4) auto 0; }

/* Gạch lime trang trí dưới tiêu đề (thay cho ảnh line.png của benchmark) */
/* Vẽ bằng background của chính chữ, không dùng z-index âm —
   z-index âm hay bị chìm khi cha tạo ngữ cảnh xếp lớp mới. */
.underline-lime {
  display: inline;
  background-image: linear-gradient(var(--lime), var(--lime));
  background-repeat: no-repeat;
  background-size: 100% .32em;
  background-position: 0 88%;
  border-radius: 2px;
}

/* ---------------- Ảnh giữ chỗ ----------------
   Chưa có nguyên liệu thật. Mọi khối ảnh dùng class này,
   thay bằng <img> khi sếp nạp ảnh/video vào.                */

.ph {
  position: relative; overflow: hidden;
  border-radius: var(--r-lg);
  background:
    linear-gradient(135deg, var(--lime-wash) 0%, #E8EEDC 55%, #DEE2E6 100%);
  display: grid; place-items: center;
  color: var(--ink-4); font-size: var(--fs-xs); font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase;
}
.ph::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    repeating-linear-gradient(45deg, rgba(28,24,53,.04) 0 10px, transparent 10px 20px);
}
.ph > span { position: relative; z-index: 1; padding: var(--s-2) var(--s-3);
             background: rgba(255,255,255,.75); border-radius: var(--r-pill); }
.ph--9x16 { aspect-ratio: 9 / 16; }
.ph--1x1  { aspect-ratio: 1 / 1; }
.ph--16x9 { aspect-ratio: 16 / 9; }
.ph--4x5  { aspect-ratio: 4 / 5; }

/* ---------------- Logo (dùng ở mọi trang) ---------------- */

.logo { display: flex; align-items: center; gap: var(--s-3); font-weight: 900;
        font-size: 20px; color: var(--ink); letter-spacing: -.03em; }
.logo__mark {
  width: 36px; height: 36px; border-radius: var(--r-md);
  background: var(--lime); display: grid; place-items: center;
  font-size: 18px; font-weight: 900; color: var(--ink);
}

/* Pill nhiều dòng — dùng khi nhãn dài */
.pill--wrap { height: auto; padding: var(--s-2) var(--s-4); white-space: normal;
              text-align: center; line-height: 1.4; }
