/* Võ Lâm Chiến Mệnh - trang chủ + tài khoản. Không cần build: sửa file là xong. */
:root {
  --ink: #0a0d14;          /* nền trang */
  --ink-2: #111725;        /* mặt thẻ */
  --ink-3: #182033;        /* mặt nổi */
  --field: #0d1220;        /* ô nhập */
  --edge: #263049;         /* viền ô nhập */
  --line: rgba(232, 184, 74, .22);
  --line-hi: rgba(232, 184, 74, .55);
  --gold: #e8b84a;
  --gold-hi: #f6d98b;
  --gold-deep: #b9821c;
  --red: #b4231b;
  --red-hi: #d43b2a;
  --parch: #efe4cc;        /* chữ chính */
  --mute: #a39b88;         /* chữ phụ */
  --ok: #74d38a;
  --warn: #f0c35a;
  --bad: #ff7d6b;
  --radius: 12px;
  --head-h: 68px;
  --wrap: 1180px;
  --serif: "Noto Serif", Georgia, "Times New Roman", serif;
  --sans: "Be Vietnam Pro", "Segoe UI", Tahoma, Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--head-h) + 12px); }
body {
  margin: 0;
  background: var(--ink);
  color: var(--parch);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--gold-hi); text-decoration: none; }
a:hover { color: #fff1c9; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.25; margin: 0; letter-spacing: .01em; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--gold-hi); outline-offset: 3px; border-radius: 6px; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* ── Nút ─────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 11px 22px; border-radius: 10px; border: 1px solid transparent;
  font: 600 15px/1.2 var(--sans); letter-spacing: .02em; cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .55; cursor: wait; transform: none; }
.btn-gold {
  color: #2b1500;
  background: linear-gradient(180deg, #fbe5a4 0%, #e8b84a 48%, #c68e22 100%);
  box-shadow: 0 8px 24px rgba(232, 184, 74, .28), inset 0 1px 0 rgba(255, 255, 255, .65);
}
.btn-gold:hover { color: #2b1500; transform: translateY(-2px); box-shadow: 0 12px 30px rgba(232, 184, 74, .4), inset 0 1px 0 rgba(255, 255, 255, .7); }
.btn-red {
  color: #fff3dc;
  background: linear-gradient(180deg, #e04a36 0%, #b4231b 55%, #8a1610 100%);
  box-shadow: 0 8px 22px rgba(180, 35, 27, .35), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.btn-red:hover { color: #fff; transform: translateY(-2px); }
.btn-ghost { color: var(--gold-hi); border-color: var(--line-hi); background: rgba(10, 13, 20, .35); }
.btn-ghost:hover { color: #fff1c9; border-color: var(--gold); background: rgba(232, 184, 74, .08); }
.btn-lg { padding: 15px 30px; font-size: 17px; border-radius: 12px; }
.btn-block { width: 100%; }

/* Nút tải game: dòng chữ chính + dòng thông số */
.btn-download { padding: 14px 30px 14px 24px; text-align: left; }
.btn-download svg { width: 26px; height: 26px; }
.btn-download .lbl { display: flex; flex-direction: column; gap: 2px; }
.btn-download .lbl b { font-size: 18px; letter-spacing: .03em; }
.btn-download .lbl small { font-size: 12px; font-weight: 500; opacity: .8; }

/* ── Thanh trên ──────────────────────────────────────────────────────── */
.site-head {
  position: fixed; inset: 0 0 auto 0; height: var(--head-h); z-index: 50;
  background: linear-gradient(180deg, rgba(10, 13, 20, .92), rgba(10, 13, 20, .72));
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-head .wrap { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--parch); flex: none; }
.brand img { width: 40px; height: 40px; }
.brand span { font: 700 16px/1.1 var(--serif); letter-spacing: .08em; text-transform: uppercase; }
.brand:hover { color: #fff; }
.menu { display: flex; align-items: center; gap: 20px; flex: 1; }
.nav { display: flex; gap: 6px; margin-right: auto; }
.nav a { color: var(--parch); opacity: .82; padding: 8px 12px; border-radius: 8px; font-weight: 500; font-size: 15px; }
.nav a:hover, .nav a[aria-current="page"] { opacity: 1; color: var(--gold-hi); background: rgba(232, 184, 74, .07); }
.head-actions { display: flex; align-items: center; gap: 10px; }
.head-actions .btn { padding: 9px 18px; font-size: 14px; }
.user-chip { display: inline-flex; align-items: center; gap: 8px; color: var(--gold-hi); font-weight: 600; font-size: 14px;
  padding: 8px 14px; border: 1px solid var(--line-hi); border-radius: 999px; background: rgba(232, 184, 74, .06); }
.user-chip svg { width: 16px; height: 16px; }
.menu-btn { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 8px; color: var(--parch);
  width: 42px; height: 42px; cursor: pointer; align-items: center; justify-content: center; }
.menu-btn svg { width: 22px; height: 22px; }

/* ── Phần đầu trang ──────────────────────────────────────────────────── */
.hero {
  position: relative; min-height: min(100vh, 920px); display: flex; align-items: center;
  padding: calc(var(--head-h) + 40px) 0 90px; isolation: isolate; overflow: hidden;
  background: var(--ink) url("../img/nen-nui.jpg") center 35% / cover no-repeat;
}
.hero::before {               /* phủ tối để chữ đọc được, chuyển dần về màu nền ở đáy */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(ellipse 60% 55% at 32% 45%, rgba(10, 13, 20, .15), rgba(10, 13, 20, .55) 70%),
    linear-gradient(180deg, rgba(10, 13, 20, .55) 0%, rgba(10, 13, 20, .25) 35%, rgba(10, 13, 20, .7) 75%, var(--ink) 100%);
}
.hero-art {                   /* tranh nhân vật, chỉ màn rộng */
  position: absolute; right: max(10px, calc((100vw - var(--wrap)) / 2)); bottom: 0; z-index: -1;
  height: min(84%, 760px); pointer-events: none;
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, .55));
}
.hero-glow { position: absolute; right: calc(max(10px, calc((100vw - var(--wrap)) / 2)) + 40px); bottom: 12%;
  width: 420px; height: 420px; z-index: -2; border-radius: 50%;
  background: radial-gradient(circle, rgba(246, 217, 139, .32), rgba(232, 184, 74, .08) 55%, transparent 70%); filter: blur(10px); }
.hero-body { max-width: 620px; }
.hero-logo { width: clamp(280px, 44vw, 580px); margin: 0 0 10px -14px; filter: drop-shadow(0 14px 28px rgba(0, 0, 0, .6)); }
.hero-tag { font: 600 clamp(19px, 2.1vw, 24px)/1.4 var(--serif); color: #fff3d6; text-shadow: 0 2px 12px rgba(0, 0, 0, .8); }
.hero-sub { margin-top: 10px; color: #d9d0bb; max-width: 520px; text-shadow: 0 1px 8px rgba(0, 0, 0, .8); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 30px; }
.hero-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; margin-top: 22px; font-size: 14px; color: #cfc6b2; }

.pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px;
  background: rgba(10, 13, 20, .6); border: 1px solid var(--line); font-size: 14px; font-weight: 500; }
.fb-link { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; font-size: 14px; font-weight: 600;
  color: #d6e4ff; background: rgba(24, 119, 242, .16); border: 1px solid rgba(24, 119, 242, .55); }
.fb-link:hover { color: #fff; background: rgba(24, 119, 242, .3); }
.fb-link svg { width: 16px; height: 16px; }
.dot { width: 9px; height: 9px; border-radius: 50%; background: var(--mute); box-shadow: 0 0 0 3px rgba(255, 255, 255, .06); flex: none; }
.dot.ok { background: var(--ok); box-shadow: 0 0 10px rgba(116, 211, 138, .7); }
.dot.warn { background: var(--warn); }
.dot.bad { background: var(--bad); }

.scroll-hint { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); color: var(--mute); font-size: 12px;
  letter-spacing: .25em; text-transform: uppercase; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.scroll-hint i { width: 1px; height: 34px; background: linear-gradient(var(--gold), transparent); animation: drip 2.2s ease-in-out infinite; }
@keyframes drip { 0%, 100% { opacity: .25; transform: scaleY(.6); transform-origin: top; } 50% { opacity: 1; transform: scaleY(1); } }

/* ── Khối nội dung chung ─────────────────────────────────────────────── */
.section { padding: 96px 0; position: relative; }
.section-alt { background: linear-gradient(180deg, transparent, rgba(24, 32, 51, .45) 18%, rgba(24, 32, 51, .45) 82%, transparent); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 48px; }
.eyebrow { display: inline-flex; align-items: center; gap: 12px; color: var(--gold); font: 600 13px/1 var(--sans);
  letter-spacing: .28em; text-transform: uppercase; }
.eyebrow::before, .eyebrow::after { content: ""; width: 34px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.eyebrow::after { transform: scaleX(-1); }
.section-head h2 { font-size: clamp(28px, 3.4vw, 40px); margin: 14px 0 12px; color: #fff4dc; }
.section-head p { color: var(--mute); }

.card {
  background: linear-gradient(180deg, rgba(24, 32, 51, .92), rgba(17, 23, 37, .94));
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 20px 50px rgba(0, 0, 0, .35);
}

/* Tính năng */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }   /* 6 thẻ = 3 + 3 */
@media (max-width: 980px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .features { grid-template-columns: 1fr; } }
.feature { padding: 26px 24px 24px; transition: transform .2s ease, border-color .2s ease; }
.feature:hover { transform: translateY(-4px); border-color: var(--line-hi); }
.feature .ico { width: 52px; height: 52px; display: grid; place-items: center; margin-bottom: 18px; color: var(--gold-hi);
  border: 1px solid var(--line-hi); border-radius: 14px; background: radial-gradient(circle at 30% 25%, rgba(246, 217, 139, .18), rgba(180, 35, 27, .12)); }
.feature .ico svg { width: 26px; height: 26px; }
.feature h3 { font-size: 20px; color: #fff1d2; margin-bottom: 8px; }
.feature p { color: var(--mute); font-size: 15px; }

/* Máy chủ + tin */
.duo { display: grid; grid-template-columns: 1fr 1.25fr; gap: 22px; align-items: start; }
.panel { padding: 24px; }
.panel h3 { font-size: 20px; color: #fff1d2; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.panel h3 svg { width: 20px; height: 20px; color: var(--gold); }
.server-list, .news-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.server-row { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 10px; background: rgba(10, 13, 20, .5); border: 1px solid rgba(255, 255, 255, .04); }
.server-row .name { font-weight: 600; flex: 1; }
.server-row .state { font-size: 14px; color: var(--mute); }
.tag { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 3px 8px; border-radius: 6px;
  color: #2b1500; background: var(--gold); }
.tag.red { background: var(--red-hi); color: #fff3dc; }
.news-row > * { display: flex; gap: 14px; align-items: baseline; padding: 12px 14px; border-radius: 10px; color: var(--parch);
  background: rgba(10, 13, 20, .45); border: 1px solid rgba(255, 255, 255, .04); }
.news-row a:hover { border-color: var(--line-hi); color: #fff; }
.news-row .date { flex: none; font-size: 13px; color: var(--gold); font-variant-numeric: tabular-nums; min-width: 46px; }
.banner-box { margin-bottom: 16px; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: 11 / 5; background: var(--ink-3); }
.banner-box img { width: 100%; height: 100%; object-fit: cover; }
.muted { color: var(--mute); font-size: 15px; }

/* Tải game */
.download { display: grid; grid-template-columns: 1.15fr 1fr; gap: 48px; align-items: center; }
.shot { position: relative; border-radius: 14px; overflow: hidden; border: 1px solid var(--line-hi);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .55), 0 0 0 6px rgba(232, 184, 74, .06); }
.shot img { width: 100%; }
.steps { list-style: none; padding: 0; margin: 26px 0 30px; display: grid; gap: 16px; counter-reset: s; }
.steps li { display: grid; grid-template-columns: 38px 1fr; gap: 14px; align-items: start; counter-increment: s; }
.steps li::before { content: counter(s); width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  font: 700 16px/1 var(--serif); color: #2b1500; background: linear-gradient(180deg, #fbe5a4, #d9a531); }
.steps b { display: block; color: #fff1d2; }
.steps span { color: var(--mute); font-size: 15px; }
.req { margin-top: 14px; font-size: 13px; color: var(--mute); }
.download h2 { font-size: clamp(28px, 3vw, 38px); color: #fff4dc; margin-top: 12px; }

/* Chân trang */
.site-foot { border-top: 1px solid var(--line); padding: 40px 0 34px; background: #080a10; color: var(--mute); font-size: 14px; }
.site-foot .wrap { display: grid; grid-template-columns: auto 1fr auto; gap: 28px; align-items: center; }
.site-foot img { width: 170px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 22px; justify-content: center; }
.foot-links a { color: var(--parch); opacity: .8; }
.age { display: flex; align-items: center; gap: 10px; max-width: 330px; }
.age b { flex: none; font: 700 18px/1 var(--sans); color: #fff; border: 2px solid var(--red-hi); border-radius: 8px; padding: 6px 7px; }
.copy { grid-column: 1 / -1; text-align: center; font-size: 13px; opacity: .7; }

/* ── Trang tài khoản ─────────────────────────────────────────────────── */
.page-top {
  padding: calc(var(--head-h) + 56px) 0 70px; position: relative; isolation: isolate;
  background: var(--ink) url("../img/nen-nui.jpg") center 30% / cover no-repeat;
}
.page-top::before { content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(10, 13, 20, .7), rgba(10, 13, 20, .82) 70%, var(--ink)); }
.page-top h1 { font-size: clamp(30px, 4vw, 44px); color: #fff4dc; }
.page-top p { color: #d4cbb6; margin-top: 8px; }
.account-main { margin-top: -30px; padding-bottom: 90px; position: relative; }

.auth-card { max-width: 460px; margin: 0 auto; padding: 28px; }
.tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 5px; border-radius: 12px; background: var(--field); border: 1px solid var(--edge); margin-bottom: 24px; }
.tabs button { border: 0; background: none; color: var(--mute); font: 600 15px/1 var(--sans); padding: 11px; border-radius: 9px; cursor: pointer; }
.tabs button[aria-selected="true"] { color: #2b1500; background: linear-gradient(180deg, #fbe5a4, #d9a531); }

.form { display: grid; gap: 16px; }
.field { display: grid; gap: 7px; }
.field label { font-size: 14px; font-weight: 600; color: #e6dcc6; }
.field .hint { font-size: 12.5px; color: var(--mute); }
.input-wrap { position: relative; }
.input-wrap input { padding-right: 46px; }
input[type="text"], input[type="password"] {
  width: 100%; padding: 12px 14px; border-radius: 9px; border: 1px solid var(--edge); background: var(--field);
  color: var(--parch); font: 500 15px/1.3 var(--sans); transition: border-color .15s, box-shadow .15s;
}
input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(232, 184, 74, .18); }
input[aria-invalid="true"] { border-color: var(--bad); }
.eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 8px;
  background: none; color: var(--mute); cursor: pointer; display: grid; place-items: center; }
.eye:hover { color: var(--gold-hi); }
.eye svg { width: 18px; height: 18px; }
.msg { min-height: 22px; font-size: 14px; }
.msg.ok { color: var(--ok); }
.msg.bad { color: var(--bad); }
.form-foot { text-align: center; font-size: 14px; color: var(--mute); }
.linklike { background: none; border: 0; padding: 0; color: var(--gold-hi); font: inherit; cursor: pointer; }
.linklike:hover { color: #fff1c9; text-decoration: underline; }

.acc-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 22px; align-items: start; }
.profile { padding: 26px; }
.profile-head { display: flex; align-items: center; gap: 18px; padding-bottom: 20px; border-bottom: 1px solid var(--line); margin-bottom: 20px; }
.avatar { width: 72px; height: 72px; flex: none; border-radius: 16px; display: grid; place-items: center;
  background: radial-gradient(circle at 30% 25%, rgba(246, 217, 139, .25), rgba(180, 35, 27, .25)); border: 1px solid var(--line-hi); }
.avatar img { width: 58px; height: 58px; }
.profile-head h2 { font-size: 26px; color: #fff4dc; word-break: break-all; }
.profile-head .sub { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 6px; font-size: 14px; color: var(--mute); }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; padding: 3px 10px; border-radius: 999px;
  border: 1px solid currentColor; }
.badge.ok { color: var(--ok); }
.badge.bad { color: var(--bad); }
.badge.gold { color: var(--gold); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin: 0; }
.facts div { padding: 14px 16px; border-radius: 10px; background: rgba(10, 13, 20, .5); border: 1px solid rgba(255, 255, 255, .04); }
.facts dt { font-size: 12.5px; color: var(--mute); text-transform: uppercase; letter-spacing: .08em; }
.facts dd { margin: 4px 0 0; font-weight: 600; color: #f6ecd6; word-break: break-word; }
.block-title { font-size: 19px; color: #fff1d2; margin: 28px 0 14px; display: flex; align-items: center; gap: 10px; }
.block-title svg { width: 19px; height: 19px; color: var(--gold); }
.roles { width: 100%; border-collapse: collapse; font-size: 15px; }
.roles th { text-align: left; font-size: 12.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--mute); font-weight: 600;
  padding: 0 12px 10px; border-bottom: 1px solid var(--line); }
.roles td { padding: 12px; border-bottom: 1px solid rgba(255, 255, 255, .05); }
.roles td.num { font-variant-numeric: tabular-nums; color: var(--gold-hi); font-weight: 700; }
.empty { padding: 18px; border-radius: 10px; border: 1px dashed var(--line); color: var(--mute); text-align: center; font-size: 15px; }
.side { display: grid; gap: 22px; }
.side .card { padding: 24px; }
.side h3 { font-size: 19px; color: #fff1d2; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; }
.side h3 svg { width: 19px; height: 19px; color: var(--gold); }
.quick { display: grid; gap: 10px; }

/* ── Màn hẹp ─────────────────────────────────────────────────────────── */
@media (max-width: 1080px) {
  .hero-art, .hero-glow { opacity: .35; }
}
@media (max-width: 900px) {
  .hero-art, .hero-glow { display: none; }
  .hero { text-align: center; }
  .hero-body { margin: 0 auto; }
  .hero-logo { margin: 0 auto 10px; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .hero-cta, .hero-meta { justify-content: center; }
  .duo, .download, .acc-grid { grid-template-columns: 1fr; }
  .download { gap: 32px; }
  .site-foot .wrap { grid-template-columns: 1fr; justify-items: center; text-align: center; }
}
@media (max-width: 820px) {
  .menu-btn { display: inline-flex; }
  .menu {
    display: none; position: absolute; left: 0; right: 0; top: var(--head-h);
    flex-direction: column; align-items: stretch; gap: 12px; padding: 10px 20px 18px;
    background: rgba(10, 13, 20, .97); border-bottom: 1px solid var(--line);
  }
  .site-head.open .menu { display: flex; }
  .nav { display: grid; gap: 2px; margin: 0; }
  .nav a { padding: 12px; }
  .head-actions .btn { flex: 1; }
  .user-chip { flex: 1; justify-content: center; }
}
@media (max-width: 520px) {
  .section { padding: 70px 0; }
  .btn-lg, .btn-download { width: 100%; }
  .auth-card, .profile, .panel { padding: 20px; }
  .roles th:nth-child(3), .roles td:nth-child(3) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
