/* EzCursor – trang giới thiệu. Màu lấy từ con trỏ Liquid Drop: mint → xanh → hồng. */
@font-face { font-family: "Chakra Petch"; src: url(fonts/ChakraPetch-SemiBold.woff2) format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Chakra Petch"; src: url(fonts/ChakraPetch-Bold.woff2) format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Be Vietnam Pro"; src: url(fonts/BeVietnamPro-Regular.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Be Vietnam Pro"; src: url(fonts/BeVietnamPro-SemiBold.woff2) format("woff2"); font-weight: 600; font-display: swap; }

:root {
  color-scheme: dark;
  --night: #0C0F17;
  --panel: #141927;
  --panel-2: #1A2032;
  --line: #262E42;
  --ink: #ECEFF6;
  --ink-2: #C3C9D8;
  --muted: #8E97AD;
  --mint: #2EE59D;
  --blue: #2F80FF;
  --pink: #FF2E93;
  --drop: linear-gradient(135deg, var(--mint), var(--blue) 55%, var(--pink));
  --head: "Chakra Petch", "Segoe UI", sans-serif;
  --body: "Be Vietnam Pro", "Segoe UI", system-ui, sans-serif;
  --gutter: clamp(16px, 4vw, 40px);
  --measure: 66ch;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--night);
  color: var(--ink-2);
  font: 400 17px/1.65 var(--body);
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration-color: var(--blue); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--pink); }
:focus-visible { outline: 2px solid var(--mint); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--head); color: var(--ink); line-height: 1.12; margin: 0; letter-spacing: -0.01em; }
h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 600; }
p { margin: 0; }
code { font: 600 0.92em var(--head); color: var(--ink); background: var(--panel-2); padding: 1px 6px; border-radius: 5px; }
.wrap { width: min(1120px, 100%); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--night); padding: 8px 12px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 8px; }

/* ---------- Thanh điều hướng */
.nav {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 24px;
  height: 64px; padding-inline: var(--gutter);
  background: rgba(12, 15, 23, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 700 21px var(--head); color: var(--ink); }
.brand b { color: var(--pink); font-weight: 700; }
.nav nav { display: flex; gap: 22px; margin-left: auto; }
.nav nav a { color: var(--ink-2); text-decoration: none; font-size: 15px; }
.nav nav a:hover { color: var(--ink); }
.nav-tools { display: flex; align-items: center; gap: 14px; }
.lang { display: flex; border: 1px solid var(--line); border-radius: 8px; padding: 2px; }
.lang button {
  font: 600 13px var(--head); color: var(--muted); background: none; border: 0;
  padding: 4px 9px; border-radius: 6px; cursor: pointer;
}
.lang button[aria-pressed="true"] { color: var(--ink); background: var(--panel-2); }
.gh { color: var(--ink-2); display: grid; place-items: center; }
.gh:hover { color: var(--ink); }

/* ---------- Hero: một cảnh "hầm ngục" tối để thử con trỏ */
.hero {
  position: relative;
  min-height: min(86vh, 780px);
  display: flex; align-items: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: radial-gradient(120% 90% at 75% 40%, #1A1430 0%, #0E1020 45%, var(--night) 80%);
}
.hero.ez-on { cursor: url(images/cursor-drop-48.png) 4 4, auto; }
@supports (cursor: image-set(url(a.png) 1x)) {
  .hero.ez-on { cursor: image-set(url(images/cursor-drop-48.png) 1x, url(images/cursor-drop-96.png) 2x) 4 4, auto; }
}
.hero.ez-on a, .hero.ez-on label, .hero.ez-on input { cursor: inherit; }
.hero-scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-drop {
  position: absolute; right: max(4vw, calc((100vw - 1120px) / 2)); top: 50%;
  width: clamp(220px, 24vw, 320px); transform: translateY(-50%) rotate(-8deg);
  filter: drop-shadow(0 0 40px rgba(47, 128, 255, 0.45)) drop-shadow(0 0 90px rgba(255, 46, 147, 0.25));
  pointer-events: none; animation: bob 6s ease-in-out infinite;
}
@keyframes bob { 50% { transform: translateY(calc(-50% - 14px)) rotate(-5deg); } }
@media (max-width: 1000px) { .hero-drop { display: none; } }
.hero-inner {
  position: relative;
  width: min(1120px, 100%); margin-inline: auto; padding: 72px var(--gutter);
}
.hero h1 {
  font-size: clamp(40px, 6.4vw, 80px);
  max-width: 15ch;
  text-wrap: balance;
}
.hero .lead { max-width: 46ch; margin-top: 22px; font-size: clamp(17px, 1.6vw, 20px); color: var(--ink-2); }
.cta { margin-top: 34px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font: 700 17px var(--head); text-decoration: none;
  padding: 15px 26px; border-radius: 12px;
}
.btn-main { background: var(--pink); color: #fff; box-shadow: 0 8px 30px -8px rgba(255, 46, 147, 0.65); }
.btn-main:hover { background: #ff4aa3; }
.dl-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 14px; color: var(--muted); }
.dl-meta span:empty { display: none; }
.dl-meta [data-ver] { color: var(--ink-2); }

.demo-toggle { margin-top: 56px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.switch { display: inline-flex; align-items: center; gap: 12px; font: 600 15px var(--head); color: var(--ink); cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.track { width: 46px; height: 26px; border-radius: 13px; background: #2A3146; position: relative; transition: background .2s; flex: none; }
.track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .2s; }
.switch input:checked + .track { background: var(--pink); }
.switch input:checked + .track::after { transform: translateX(20px); }
.switch input:focus-visible + .track { outline: 2px solid var(--mint); outline-offset: 3px; }
.demo-hint { font-size: 14px; color: var(--muted); max-width: 44ch; }

/* ---------- Giới thiệu */
section.wrap { padding-block: clamp(64px, 9vw, 112px); }
.about { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.about h2 { max-width: 16ch; }
.about-text p { margin-top: 18px; max-width: var(--measure); }
.facts { margin: 6px 0 0; display: grid; gap: 26px; }
.facts div { padding-left: 18px; border-left: 2px solid var(--line); }
.facts div:first-child { border-image: var(--drop) 1; }
.facts dt { font: 600 18px var(--head); color: var(--ink); }
.facts dd { margin: 4px 0 0; color: var(--ink-2); }

/* ---------- Ảnh giao diện: thanh tab giống app */
.shots { border-top: 1px solid var(--line); }
.viewer { margin-top: 32px; display: grid; grid-template-columns: 200px 1fr; gap: 28px; align-items: start; }
.tabs { display: flex; flex-direction: column; gap: 6px; position: sticky; top: 88px; }
.tabs button {
  text-align: left; font: 600 16px var(--head); color: var(--ink-2);
  background: none; border: 1px solid transparent; border-radius: 10px;
  padding: 11px 14px; cursor: pointer;
}
.tabs button:hover { background: var(--panel); color: var(--ink); }
.tabs button[aria-selected="true"] { color: #fff; border-color: var(--pink); background: rgba(255, 46, 147, 0.12); }
.shot { margin: 0; }
.shot img {
  width: 100%; border-radius: 14px; border: 1px solid var(--line);
  box-shadow: 0 30px 80px -30px rgba(47, 128, 255, 0.35);
  background: var(--panel);
}
.shot figcaption { margin-top: 14px; color: var(--muted); font-size: 15px; }

.ingame { margin-top: 72px; }
.ingame-grid { margin-top: 20px; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.ingame figure { margin: 0; }
.ingame-video { margin-top: 20px !important; }
.ingame-video video { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); background: #000; }
.ingame-video figcaption { margin-top: 8px; font-size: 14px; color: var(--muted); }
.ingame img { width: 100%; border-radius: 12px; border: 1px solid var(--line); aspect-ratio: 16 / 9; object-fit: cover; }
.ingame figcaption { margin-top: 8px; font-size: 14px; color: var(--muted); }
.ingame .missing {
  aspect-ratio: 16 / 9; border-radius: 12px; border: 1px dashed #3A4460;
  display: grid; place-items: center; text-align: center; padding: 16px;
  color: var(--muted); font-size: 14px;
}
.ingame .missing code { display: inline-block; margin-top: 6px; }

/* ---------- Tính năng */
.features { border-top: 1px solid var(--line); }
.feat-list { list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 28px 56px; }
.feat-list li { position: relative; padding-left: 26px; max-width: 52ch; }
.feat-list li::before {
  content: ""; position: absolute; left: 0; top: 8px; width: 11px; height: 11px;
  border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--drop);
}
.feat-list strong { display: block; font: 600 18px var(--head); color: var(--ink); margin-bottom: 2px; }

/* ---------- Thư viện con trỏ */
.library { border-top: 1px solid var(--line); }
.lib-lead { max-width: var(--measure); margin-top: 12px; }
.lib-lead code { font-size: 0.9em; color: var(--ink); }
.lib-grid { margin-top: 32px; display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; }
.lib-card {
  position: relative; margin: 0; padding: 22px 14px 16px; display: flex; flex-direction: column; align-items: center; gap: 10px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 14px; text-align: center;
  transition: border-color .2s, transform .2s;
}
.lib-card:hover { border-color: #3A4560; transform: translateY(-2px); }
.lib-card img { width: 84px; height: 84px; object-fit: contain; }
.lib-card figcaption { font: 600 16px var(--head); color: var(--ink); line-height: 1.3; }
.lib-dl {
  margin-top: auto; font: 600 14px var(--head); color: var(--ink); text-decoration: none;
  padding: 7px 18px; border-radius: 9px; border: 1px solid var(--pink); background: rgba(255, 46, 147, 0.10);
}
.lib-dl:hover { background: rgba(255, 46, 147, 0.22); }
.lib-new {
  position: absolute; top: 10px; left: 10px; font: 700 11px var(--head); letter-spacing: .06em;
  color: #0B0D12; background: var(--mint); border-radius: 6px; padding: 1px 7px;
}
.lib-empty { margin-top: 24px; color: var(--muted); }

/* ---------- Hướng dẫn */
.guide { border-top: 1px solid var(--line); display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px clamp(32px, 6vw, 80px); }
.guide h2 { grid-column: 1 / -1; }
.steps { list-style: none; margin: 16px 0 0; padding: 0; counter-reset: s; display: grid; gap: 30px; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 52px 1fr; column-gap: 18px; }
.steps li::before {
  content: counter(s); grid-row: span 2;
  width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center;
  font: 700 22px var(--head); color: var(--night); background: var(--mint);
}
.steps li:nth-child(2)::before { background: #2FB0D8; }
.steps li:nth-child(3)::before { background: var(--blue); color: #fff; }
.steps li:nth-child(4)::before { background: var(--pink); color: #fff; }
.steps h3 { margin-top: 8px; }
.steps p { margin-top: 6px; max-width: 58ch; }
.keys { margin-top: 16px; align-self: start; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 22px 22px 10px; }
.keys table { width: 100%; border-collapse: collapse; margin-top: 12px; }
.keys td { padding: 11px 0; border-top: 1px solid var(--line); font-size: 15px; }
.keys td:first-child { white-space: nowrap; padding-right: 16px; }
.keys-note { font-size: 14px; color: var(--muted); padding: 10px 0 12px; border-top: 1px solid var(--line); }
kbd {
  display: inline-block; min-width: 26px; text-align: center;
  font: 600 13px var(--head); color: var(--ink);
  background: var(--panel-2); border: 1px solid #333C55; border-bottom-width: 2px;
  border-radius: 6px; padding: 2px 7px;
}

/* ---------- Hỏi đáp */
.faq { border-top: 1px solid var(--line); }
.faq > * { max-width: 860px; }
.faq h2 { margin-bottom: 20px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 20px 40px 20px 0; position: relative;
  font: 600 18px var(--head); color: var(--ink);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 6px; top: 50%; width: 10px; height: 10px;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: translateY(-70%) rotate(45deg); transition: transform .2s;
}
.faq details[open] summary::after { transform: translateY(-30%) rotate(225deg); }
.faq details p { padding-bottom: 22px; max-width: var(--measure); }

/* ---------- Ủng hộ */
.support { border-top: 1px solid var(--line); }
.support-head { display: grid; grid-template-columns: 1fr 1.2fr; gap: 16px 56px; align-items: end; }
.support-head p { max-width: 54ch; }
.methods { margin-top: 40px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.method { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.method[data-method="momo"] { border-top: 3px solid #D82D8B; }
.method[data-method="bank"] { border-top: 3px solid var(--mint); }
.method[data-method="paypal"] { border-top: 3px solid var(--blue); }
.qr img { width: 100%; max-width: 240px; aspect-ratio: 1; object-fit: contain; background: #fff; border-radius: 10px; padding: 8px; }
.qr:empty { display: none; }
.method-note { color: var(--muted); font-size: 15px; }
.acct { display: grid; gap: 4px; font-size: 15px; }
.acct .row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.acct .label { color: var(--muted); }
.acct .val { color: var(--ink); font: 600 16px var(--head); letter-spacing: 0.02em; }
.copy {
  font: 600 12px var(--head); color: var(--ink-2); background: var(--panel-2);
  border: 1px solid var(--line); border-radius: 6px; padding: 3px 8px; cursor: pointer;
}
.copy:hover { color: var(--ink); border-color: #3A4460; }
.btn-paypal { align-self: flex-start; background: #FFC439; color: #111; font-size: 16px; padding: 12px 22px; }
.btn-paypal:hover { background: #ffd162; }
.pending { color: var(--muted); font-size: 14px; border: 1px dashed #3A4460; border-radius: 10px; padding: 12px; }
.support-alt { margin-top: 28px; color: var(--muted); font-size: 15px; }

/* ---------- Chân trang */
.foot { border-top: 1px solid var(--line); padding-block: 36px 48px; display: grid; gap: 10px; font-size: 14px; color: var(--muted); }
.foot a { color: var(--ink-2); }
.foot-brand { display: flex; align-items: center; gap: 10px; font: 700 18px var(--head); color: var(--ink); }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px);
  background: var(--ink); color: var(--night); font: 600 14px var(--head);
  padding: 10px 16px; border-radius: 10px; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Màn hình nhỏ */
@media (max-width: 900px) {
  .nav nav { display: none; }
  .nav-tools { margin-left: auto; }
  .about, .guide, .support-head { grid-template-columns: 1fr; }
  .viewer { grid-template-columns: 1fr; }
  .tabs { position: static; flex-direction: row; overflow-x: auto; scrollbar-width: none; }
  .tabs button { white-space: nowrap; }
  .feat-list { grid-template-columns: 1fr; }
  .methods { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .hero { min-height: auto; }
  .hero-inner { padding-block: 56px 48px; }
  .btn-main { width: 100%; justify-content: center; }
  .keys td:first-child { white-space: normal; }
}
@media (hover: none) { .demo-toggle { display: none; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .track, .track::after, .toast, .faq summary::after { transition: none; }
  .hero-drop { animation: none; }
}
