/* Locket Gold Shop — neobrutalism đồng bộ ui/: font Itim, nền giấy, viền đen, bóng rắn.
   100% icon là Font Awesome (CSS), không dùng emoji/unicode icon. */

:root {
  --paper-0: #fffcef;
  --paper-1: #faf5df;
  --ink-900: #111;
  --ink-700: #33322d;
  --ink-500: #6b613e;
  --ink-300: #b6b09a;
  --main-hi: #ffd94a;
  --green: #7bd88f;
  --red: #ff8f8f;
  --blue: #8fc7ff;
  --purple: #d7b3ff;
  --background: var(--paper-0);
  --border: var(--ink-900);
  --shadow: 4px 4px 0 0 var(--ink-900);
  --shadow-sm: 2px 2px 0 0 var(--ink-900);
  --shadow-lg: 7px 7px 0 0 var(--ink-900);
  --radius-base: 5px;
  --radius-lg: 14px;
  --font-itim: "Itim", "Noto Sans JP", cursive;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --topbar-h: 64px;

  /* Animate UI Motion Tokens (cubic-bezier & springs) */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);       /* Enters & leaves (fast start, smooth landing) */
  --ease-soft: cubic-bezier(0.215, 0.61, 0.355, 1); /* Modals backdrop, disclosures, unfold */
  --ease-drawer: cubic-bezier(0.34, 1.2, 0.64, 1);   /* Modals & sheets pop with natural spring bounce */
  --ease-away: cubic-bezier(0.33, 0.17, 0.67, 0.5);  /* Dismiss & exit speeding away */
  --ease-color: cubic-bezier(0.25, 0.1, 0.25, 1);    /* Smooth color & border highlights */
  --scale-press: 0.97;                              /* Button / control press feedback */
  --scale-choice: 0.985;                            /* Card / row choice press feedback */
  --scale-modal: 0.92;                              /* Modal initial scale */
}

* { box-sizing: border-box; }
.hidden { display: none !important; }
html { scroll-behavior: smooth; }

/* Ẩn thanh cuộn dọc */
::-webkit-scrollbar {
  display: none;
}
body {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}
body {
  margin: 0;
  font-family: var(--font-itim);
  font-size: 16px;
  line-height: 1.6;
  background: var(--background);
  color: var(--ink-900);
  background-image:
    linear-gradient(to right, #6b613e24 1px, transparent 1px),
    linear-gradient(to bottom, #6b613e38 1px, transparent 1px);
  background-size: 20px 20px;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}
input, button, select, textarea {
  font-family: var(--font-itim), inherit;
}
input::placeholder, textarea::placeholder {
  font-family: var(--font-itim), inherit;
}
h1, h2, h3, h4, h5, h6 { margin: 0; line-height: 1.25; font-family: var(--font-itim); }
a { color: inherit; }
img { max-width: 100%; }

/* Bong mau nen trang tri */
.bg-orbs { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.bg-orbs span {
  position: absolute; border-radius: 50%; filter: blur(70px); opacity: .35;
  animation: drift 12s ease-in-out infinite alternate;
}
.bg-orbs span:nth-child(1) { width: min(340px, 60vw); height: min(340px, 60vw); background: #ffd94a; top: -80px; left: -80px; }
.bg-orbs span:nth-child(2) { width: min(280px, 55vw); height: min(280px, 55vw); background: #8fc7ff; top: 30%; right: -100px; animation-delay: -4s; }
.bg-orbs span:nth-child(3) { width: min(220px, 50vw); height: min(220px, 50vw); background: #ff8f8f; bottom: -60px; left: 30%; animation-delay: -8s; }
@keyframes drift { to { transform: translate(40px, 30px) scale(1.1); } }

/* ===== Topbar ===== */
.topbar {
  position: sticky; top: 0; z-index: 50;
  min-height: var(--topbar-h);
  display: flex; align-items: center; gap: 12px;
  padding: 10px 20px;
  background: linear-gradient(180deg, #ffe066 0%, #ffd94a 60%, #f5c92e 100%) !important;
  border-bottom: 3px solid var(--border) !important;
  box-shadow: 0 3px 0 rgba(17,17,17,.12), inset 0 1px 0 rgba(255,255,255,.55);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; white-space: nowrap; }
.brand-word { font-size: 26px; line-height: 1; color: var(--ink-900); font-weight: bold; letter-spacing: -.02em; }
.brand-cam {
  background: var(--ink-900);
  color: #ffd94a;
  padding: 2px 8px;
  border-radius: var(--radius-base, 5px);
  letter-spacing: .18em;
  font-size: .55em;
  box-shadow: 2px 2px 0 rgba(17,17,17,.25);
  margin-left: 8px;
  vertical-align: middle;
  text-transform: uppercase;
}
@media (max-width: 640px) {
  .topbar { padding: 8px 12px; }
  .brand-word { font-size: 20px; }
  .brand-cam { font-size: 0.55em; }
}
.topnav { display: flex; gap: 4px; margin-left: auto; }
.topnav a { text-decoration: none; font-weight: 700; padding: 6px 12px; border-radius: var(--radius-base); white-space: nowrap; }
.topnav a:hover { background: var(--background); box-shadow: var(--shadow-sm); border-radius: var(--radius-base); }
.topnav i { margin-right: 4px; }
.top-actions { display: flex; gap: 8px; align-items: center; margin-left: auto; }
.topnav + .top-actions { margin-left: 0; }
.account-chip {
  display: inline-flex; align-items: center; gap: 4px;
  background: var(--background); border: 1px solid var(--border);
  border-radius: var(--radius-base); padding: 4px 4px 4px 10px;
  font-size: 14px; font-weight: 700; box-shadow: var(--shadow-sm);
  max-width: min(240px, 44vw);
  white-space: nowrap; overflow: hidden;
}
.account-avatar {
  flex: none; width: 24px; height: 24px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--green); border: 1px solid var(--border); border-radius: var(--radius-base);
  color: var(--ink-900); font-size: 11px;
}
.account-name { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-badge {
  flex: none; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: var(--radius-base);
  border: 1px solid var(--border); white-space: nowrap;
}
.account-badge.free { background: var(--green); }
.account-badge.wait { background: var(--main-hi); }
.account-badge.hit { background: var(--paper-1); color: var(--ink-500); }
.account-out {
  flex: none; width: 26px; height: 26px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--border); border-radius: var(--radius-base);
  background: var(--background); color: var(--ink-900); cursor: pointer; font-size: 12px;
  transition: transform 0.14s var(--ease-out), box-shadow 0.14s var(--ease-color), background-color 0.14s var(--ease-color);
  touch-action: manipulation;
}
.account-out:hover { background: var(--red); transform: translate(-1px, -1px); box-shadow: var(--shadow-sm); }
.account-out:active { transform: translate(1px, 1px) scale(var(--scale-press)); box-shadow: none; }

@media (max-width: 640px) {
  .account-chip { max-width: min(200px, 50vw); }
}

/* ===== Buttons (Animate UI Spring Tactile Feedback) ===== */
.btn {
  font-family: var(--font-itim); font-weight: 600; font-size: 15px; cursor: pointer;
  border: 1px solid var(--border); border-radius: var(--radius-base);
  padding: 10px 18px; box-shadow: var(--shadow-sm);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  text-decoration: none; color: var(--ink-900); background: var(--paper-1);
  transition: transform 0.14s var(--ease-out), box-shadow 0.14s var(--ease-color), background-color 0.14s var(--ease-color);
  white-space: nowrap;
  touch-action: manipulation;
  will-change: transform, box-shadow;
}
.btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: var(--shadow);
}
.btn:active {
  transform: translate(1px, 1px) scale(var(--scale-press));
  box-shadow: 0 0 0 transparent;
  transition-duration: 0.08s;
}
.btn:disabled { opacity: .6; cursor: wait; transform: none; box-shadow: var(--shadow-sm); }
.btn-gold { background: var(--main-hi); }
.btn-gold:hover { background: #ffe066; }
.btn-dark { background: var(--ink-900); color: #fff; }
.btn-dark:hover { background: #222; }
.btn-ghost { background: var(--background); }
.btn-ghost:hover { background: var(--paper-1); }
.btn-lg { font-size: 17px; padding: 14px 24px; }
.btn-sm { font-size: 13px; padding: 7px 12px; }
.btn-block { width: 100%; }

main { max-width: 1080px; margin: 0 auto; padding: 0 20px 80px; }

/* ===== Hero ===== */
.hero { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(20px, 4vw, 40px); padding: clamp(28px, 5vw, 56px) 0 0; align-items: center; }
.pill-live {
  display: inline-flex; align-items: center; gap: 8px; background: var(--background);
  border: 1px solid var(--border); border-radius: var(--radius-base); padding: 6px 14px;
  font-size: 13px; font-weight: 700; box-shadow: var(--shadow-sm);
}
.pill-live .dot { width: 10px; height: 10px; flex: none; border-radius: var(--radius-base); background: #22c55e; animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.hero h1 { font-size: clamp(30px, 5.2vw, 56px); margin: 16px 0 12px; overflow-wrap: anywhere; word-break: break-word; }
.hl { background: var(--main-hi); border: 1px solid var(--border); border-radius: var(--radius-base); padding: 0 10px; box-shadow: var(--shadow-sm); white-space: nowrap; display: inline-block; max-width: 100%; }
.lead { color: var(--ink-700); font-size: clamp(15px, 2vw, 18px); }
.trust-row { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.trust-row span { font-size: 13px; font-weight: 700; background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-base); padding: 4px 12px; }
.trust-row i { margin-right: 4px; color: #16a34a; }
.hero-actions { display: flex; gap: 12px; margin: 20px 0; flex-wrap: wrap; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.hstat { background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-base); box-shadow: var(--shadow-sm); padding: 10px 12px; text-align: center; }
.hstat b { display: block; font-size: clamp(17px, 2.4vw, 22px); }
.hstat span { font-size: 12px; color: var(--ink-500); font-weight: 700; }

/* Photo polish: subtle card lift for screenshots */
.hero-copy h1 { text-wrap: balance; }
.hero-copy .lead { max-width: 52ch; }
/* .plan { overflow: hidden; } */
.plan-hot { background: linear-gradient(135deg, #ffd94a 0%, #ffeea0 55%, #ffd94a 100%); }
.plan .plan-price { letter-spacing: -0.02em; }
.free-card { background: linear-gradient(135deg, #ffd94a 0%, #fff6bf 100%); }

/* Gold example screenshot */
.hero-card { position: relative; display: flex; justify-content: center; align-self: end; }
@keyframes floaty { 0%,100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-12px) rotate(1deg); } }
.gold-shot {
  position: relative; width: min(320px, 82vw);
  padding: 10px 10px 0;
  border: 1px solid var(--border); border-bottom: none;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  box-shadow: var(--shadow-lg);
  background: linear-gradient(165deg, var(--main-hi) 0%, #ffe9a8 45%, var(--paper-1) 100%);
  overflow: visible;
}
.gold-shot img {
  display: block; width: 100%; height: auto;
  border: 1px solid var(--border); border-bottom: none;
  border-radius: var(--radius-base) var(--radius-base) 0 0;
}
.float-chip {
  position: absolute; background: var(--background); border: 1px solid var(--border);
  border-radius: var(--radius-base); padding: 6px 12px; font-size: 13px; font-weight: 700;
  box-shadow: var(--shadow-sm); animation: floaty 3s ease-in-out infinite; white-space: nowrap;
  z-index: 3;
}
.float-chip i { color: #16a34a; margin-right: 4px; }
.fc1 { top: 26px; right: -16px; }

/* ===== Marquee ===== */
.marquee { 
  border-top: 1px solid var(--border); 
  border-bottom: 1px solid var(--border); 
  background: linear-gradient(90deg, #ff8a00, #e52e71);
  color: #fff; 
  overflow: hidden; 
  margin: 24px 0 0; 
  box-shadow: inset 0 0 10px rgba(0,0,0,0.2);
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
}
.marquee-track { 
  display: flex; 
  gap: 50px; 
  padding: 14px 0; 
  white-space: nowrap; 
  width: max-content; 
  animation: scrollx 100s linear infinite; 
  font-size: 18px;
  font-weight: 700;
  text-shadow: 1px 1px 0px var(--ink-900);
}
.marquee-track i { color: #fff; margin-right: 8px; font-size: 20px; }
@keyframes scrollx { to { transform: translateX(-50%); } }

/* ===== Sections ===== */
.section { padding: clamp(32px, 5vw, 52px) 0 8px; scroll-margin-top: calc(var(--topbar-h) + 12px); }
.sec-title { font-size: clamp(22px, 3.4vw, 28px); margin-bottom: 6px; }
.sec-title i { color: #b8860b; margin-right: 8px; }
.sec-sub { color: var(--ink-700); margin: 0 0 20px; }

/* Plans */
.plans { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.plan { position: relative; background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-base); box-shadow: var(--shadow); padding: 24px; display: flex; flex-direction: column; }
.plan.pop {
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-color);
  touch-action: manipulation;
  will-change: transform, box-shadow;
}
.plan.pop:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.plan.pop:active { transform: translateY(-1px) scale(var(--scale-choice)); box-shadow: var(--shadow-sm); }
.plan-hot { background: var(--main-hi); }
.plan-head { display: flex; align-items: center; gap: 10px; }
.plan-head i { font-size: 26px; }
.plan-head h3 { font-size: clamp(18px, 2.6vw, 22px); }
.hot-ribbon { position: absolute; top: -16px; right: 16px; background: var(--red); border: 1px solid var(--border); border-radius: var(--radius-base); padding: 4px 14px; font-size: 13px; font-weight: 700; box-shadow: var(--shadow-sm); }
.hot-ribbon i { margin-right: 4px; }
.plan-price { font-size: clamp(34px, 5vw, 44px); font-weight: 800; margin: 10px 0 2px; }
.plan-price d { font-size: .5em; margin-left: 2px; }
.plan-per { font-size: 13px; font-weight: 700; color: var(--ink-700); margin-bottom: 10px; }
.plan-save { display: inline-block; align-self: flex-start; background: var(--ink-900); color: #fff; border-radius: var(--radius-base); font-size: 12px; padding: 3px 12px; margin-bottom: 12px; font-weight: 700; }
.plan-feats { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 8px; }
.plan-feats i { color: #16a34a; margin-right: 8px; }
.plan-hot .plan-feats i { color: var(--ink-900); }
.plan .btn { margin-top: auto; }
.secure-note { margin-top: 16px; font-size: 13px; color: var(--ink-700); text-align: center; }
.secure-note i { margin-right: 6px; }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.step {
  background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-base);
  box-shadow: var(--shadow); padding: 20px 16px; text-align: center; position: relative;
  transition: transform 0.22s var(--ease-out), box-shadow 0.22s var(--ease-color);
  touch-action: manipulation;
}
.step:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.step:active { transform: translateY(0) scale(var(--scale-choice)); }
.step i { font-size: 30px; }
.step h3 { font-size: 17px; margin: 10px 0 6px; }
.step p { margin: 0; font-size: 14px; color: var(--ink-700); }
.step-n { position: absolute; top: -14px; left: 14px; width: 30px; height: 30px; background: var(--ink-900); color: #fff; border-radius: var(--radius-base); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; }

/* FAQ */
.faq { display: grid; gap: 12px; }
.faq-item {
  background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-base);
  box-shadow: var(--shadow-sm); padding: 6px 16px;
  transition: box-shadow 0.2s var(--ease-color), border-color 0.2s var(--ease-color);
}
.faq-item summary { cursor: pointer; font-weight: 700; padding: 10px 0; list-style: none; position: relative; padding-right: 24px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: ""; position: absolute; right: 8px; top: 50%; width: 8px; height: 8px; border-right: 2px solid var(--border); border-bottom: 2px solid var(--border); transform: translateY(-50%) rotate(45deg); transition: transform 0.25s var(--ease-out); }
.faq-item[open] summary::after { transform: translateY(-50%) rotate(225deg); }
.faq-item summary i { color: #b8860b; margin-right: 8px; }
.faq-item p { color: var(--ink-700); }

/* Footer */
.footer { border-top: 1px solid var(--border); background: var(--paper-1); }
.footer-in { max-width: 1080px; margin: 0 auto; padding: 18px 20px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.footer-in span { color: var(--ink-700); font-size: 14px; }

/* ===== Modal (Animate UI Spring Modal & Surface Blur) ===== */
.modal-back {
  display: none; position: fixed; inset: 0; background: rgba(17,17,17,.55); z-index: 100; padding: 20px; overflow-y: auto;
  transition: opacity 0.35s var(--ease-soft), backdrop-filter 0.35s var(--ease-soft);
}
.modal-back.open {
  display: flex; align-items: flex-start; justify-content: center;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.modal {
  background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-base);
  box-shadow: 10px 10px 0 0 var(--ink-900); max-width: 520px; width: 100%; margin: auto 0;
  padding: 24px; position: relative;
  animation: modalPopIn 0.35s var(--ease-drawer) both;
  will-change: transform, opacity, filter;
}
@keyframes modalPopIn {
  0% { opacity: 0; filter: blur(4px); transform: scale(var(--scale-modal)) translateY(16px); }
  75% { opacity: 1; filter: blur(0px); transform: scale(1.01) translateY(-2px); }
  100% { opacity: 1; filter: blur(0px); transform: scale(1) translateY(0); }
}
.modal-x {
  position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: var(--radius-base);
  border: 1px solid var(--border); background: var(--background); cursor: pointer; box-shadow: var(--shadow-sm); z-index: 2;
  transition: transform 0.14s var(--ease-out), background-color 0.14s var(--ease-color);
  touch-action: manipulation;
}
.modal-x:hover { background: var(--red); }
.modal-x:active { transform: scale(var(--scale-press)); }
.modal-x:hover { background: var(--red); }
.mstep h3 { margin-bottom: 14px; padding-right: 40px; }
.mstep h3 i { color: #b8860b; margin-right: 6px; }
.mstep.center { text-align: center; }
.order-pkg { background: var(--paper-1); border: 1px solid var(--border); border-radius: var(--radius-base); padding: 10px 14px; margin-bottom: 14px; font-weight: 700; }
.linked-note { display: flex; align-items: center; gap: 8px; background: var(--green); border: 1px solid var(--border); border-radius: var(--radius-base); padding: 8px 12px; margin-bottom: 14px; font-size: 14px; font-weight: 700; }
.fld { display: grid; gap: 6px; font-weight: 700; font-size: 14px; }
.fld input { font-family: var(--font-itim); font-size: 16px; padding: 12px; border: 1px solid var(--border); border-radius: var(--radius-base); outline: none; background: #fff; width: 100%; }
.fld input:focus { box-shadow: var(--shadow-sm); }
.hint { font-size: 13px; color: var(--ink-700); }
.hint i { margin-right: 4px; }
.err { color: #b3261e; font-size: 14px; font-weight: 700; min-height: 20px; margin: 8px 0 0; }
.pay-status { display: flex; align-items: center; justify-content: center; gap: 10px; font-weight: 700; background: var(--paper-1); border: 1px solid var(--border); border-radius: var(--radius-base); padding: 10px; margin-bottom: 14px; }
.pay-status.ok { background: var(--green); }
.pay-grid { display: grid; grid-template-columns: 200px 1fr; gap: 14px; align-items: start; }
#qrImg { width: 200px; height: 200px; border: 1px solid var(--border); border-radius: var(--radius-base); background: #fff; object-fit: contain; }
.pay-info { display: grid; gap: 8px; font-size: 14px; }
.pay-info .kv { background: #fff; border: 1px solid var(--border); border-radius: var(--radius-base); padding: 8px 10px; }
.pay-info .kv b { display: block; font-size: 11px; color: var(--ink-500); text-transform: uppercase; }
.pay-info .kv span { font-family: var(--mono); font-weight: 700; word-break: break-all; }
.done-ring { width: 84px; height: 84px; margin: 6px auto 14px; border-radius: var(--radius-base); background: var(--green); border: 1px solid var(--border); box-shadow: var(--shadow); display: flex; align-items: center; justify-content: center; font-size: 36px; animation: popin .4s cubic-bezier(.34,1.56,.64,1); }
.done-title { color: #16a34a; }
.spinner { width: 22px; height: 22px; flex: none; border: 3px solid var(--ink-300); border-top-color: var(--ink-900); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Cac buoc huong dan dang nhap Zalo trong modal */
.link-steps { margin: 0 0 16px; padding-left: 22px; display: grid; gap: 6px; color: var(--ink-700); font-size: 15px; }

/* Don cua toi */
.mo-list { display: grid; gap: 10px; }
.mo-row {
  display: grid; grid-template-columns: 1.2fr 1fr auto auto; align-items: center; gap: 10px;
  background: var(--background); border: 1px solid var(--border);
  border-radius: var(--radius-base); box-shadow: var(--shadow-sm); padding: 10px 14px; font-size: 14px;
}
.mo-row b { word-break: break-all; }
.mo-row > span { color: var(--ink-700); }
.mo-ok { color: #16a34a; font-weight: 700; white-space: nowrap; }
.mo-wait { color: #b8860b; font-weight: 700; white-space: nowrap; }
.mo-no { color: #b3261e; font-weight: 700; white-space: nowrap; }

/* Toast */
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px);
  background: var(--ink-900); color: #fff; padding: 12px 20px; border-radius: 8px;
  box-shadow: 4px 4px 0 #000; opacity: 0; pointer-events: none; transition: all .3s ease; z-index: 200;
  max-width: calc(100vw - 40px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .5s ease, transform .5s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* Desktop photo polish: centered modal with backdrop blur */
@media (min-width: 900px) {
  .modal-back.open { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
  .modal { box-shadow: 12px 12px 0 0 var(--ink-900); }
}

/* Desktop: phóng to ảnh, đặt sát thanh chữ chạy */
@media (min-width: 901px) {
  .hero { padding-bottom: 0; align-items: stretch; }
  .hero-copy { align-self: center; }
  .gold-shot { width: min(460px, 44vw); }
  .marquee { margin-top: 0; }
}

/* ===== Tablet (<=900px) ===== */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; text-align: center; }
  .hero-copy { order: 1; }
  .hero-card { order: 2; }
  .hero-actions, .trust-row { justify-content: center; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .plans { gap: 24px; }
  .fc1 { right: 2px; }
}

/* ===== Dien thoai (<=640px) ===== */
@media (max-width: 640px) {
  body { font-size: 15px; overflow-wrap: anywhere; }
  :root { --topbar-h: 56px; }
  .topbar { padding: 8px 12px; gap: 8px; }
  .brand-word { font-size: 21px; overflow-wrap: anywhere; }
  .brand-cam { margin-left: 6px; letter-spacing: .1em; }
  .topnav { display: none; }
  .top-actions { margin-left: auto; gap: 6px; }
  .top-actions .btn { padding: 8px 10px; font-size: 12px; gap: 5px; }
  .top-cta span { display: none; }
  .top-cta .cta-mobile { display: inline; margin-right: 0; }
  .top-cta { min-width: 38px; }
  .account-chip { max-width: 46vw; font-size: 12px; padding: 3px 3px 3px 8px; gap: 4px; }
  .account-avatar { width: 22px; height: 22px; font-size: 10px; }
  .btn-lg { font-size: 15px; padding: 12px 16px; width: 100%; }
  .hero-actions .btn { flex: 1 1 100%; }
  .hero h1 { font-size: clamp(26px, 7.5vw, 34px); overflow-wrap: anywhere; word-break: break-word; }
  .hl { white-space: nowrap; overflow-wrap: normal; word-break: keep-all; display: inline-block; border-width: 2px; padding: 0 8px; }
  .lead { overflow-wrap: anywhere; word-break: break-word; }
  .hero-stats { gap: 8px; }
  .hstat { padding: 8px 6px; min-width: 0; overflow-wrap: anywhere; }
  .hstat b { font-size: 15px; overflow-wrap: anywhere; }
  .hstat span { font-size: 11px; overflow-wrap: anywhere; }
  .sec-title, .sec-sub { overflow-wrap: anywhere; word-break: break-word; }
  .plan, .step, .faq-item { min-width: 0; overflow-wrap: anywhere; }
  .plan h3, .step h3, .step p, .faq-item summary, .faq-item p { overflow-wrap: anywhere; word-break: break-word; }
  .hero-stats { gap: 8px; }
  .hstat { padding: 8px 6px; }
  .hstat b { font-size: 15px; }
  .hstat span { font-size: 11px; }
  main { padding: 0 14px 64px; }
  .marquee { margin-top: 0; margin-left: -50vw; margin-right: -50vw; }
  .marquee-track { font-size: 15px; gap: 32px; padding: 10px 0; }
  .marquee-track i { font-size: 16px; }
  .gold-shot { width: min(340px, 90vw); }
  .gold-shot img { height: 62vh; max-height: 520px; object-fit: cover; object-position: top center; }
  .hero { padding-bottom: 0; }
  .plans { grid-template-columns: 1fr; gap: 16px; }
  .plan { padding: 18px 14px; }
  .steps { grid-template-columns: 1fr; gap: 14px; }
  .step { padding: 16px 14px; }
  .pay-grid { grid-template-columns: 1fr; }
  #qrImg { margin: 0 auto; width: min(220px, 70vw); height: auto; aspect-ratio: 1; }
  .modal-back { padding: 12px; }
  .modal { padding: 20px 16px; }
  .mo-row { grid-template-columns: 1fr 1fr; row-gap: 4px; font-size: 13px; }
  .footer-in { flex-direction: column; align-items: flex-start; gap: 4px; }
}

/* ===== Dien thoai nho (<=400px) ===== */
@media (max-width: 400px) {
  /* Đã bỏ flex-wrap topbar để dồn lên 1 hàng */
  .hero-stats { grid-template-columns: 1fr 1fr; }
  .hero-stats .hstat:last-child { grid-column: 1 / -1; }
  .plan-price { font-size: 32px; }
}

/* ===== May tinh lon (>=1200px) ===== */
@media (min-width: 1200px) {
  main { max-width: 1140px; }
  .hero { gap: 56px; }
}

/* ===== Chan in-app browser (overlay full-screen) ===== */
.browser-gate {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  padding: 20px; overflow-y: auto;
  background: var(--main-hi);
  background-image:
    linear-gradient(to right, #6b613e24 1px, transparent 1px),
    linear-gradient(to bottom, #6b613e38 1px, transparent 1px);
  background-size: 20px 20px;
}
.bg-card {
  background: var(--background); border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); max-width: 440px; width: 100%; padding: 26px 22px;
  text-align: center; margin: auto; animation: popin .3s cubic-bezier(.34,1.56,.64,1);
}
.bg-ico {
  width: 68px; height: 68px; margin: 0 auto 14px; border-radius: var(--radius-base);
  background: var(--main-hi); border: 1px solid var(--border); box-shadow: var(--shadow);
  display: flex; align-items: center; justify-content: center; font-size: 30px; color: var(--ink-900);
}
.bg-card h2 { font-size: 22px; margin-bottom: 10px; }
.bg-lead { font-size: 15px; color: var(--ink-700); margin: 0 0 18px; }
.bg-steps { text-align: left; margin: 0 0 14px; padding-left: 20px; font-size: 14px; font-weight: 700; }
.bg-steps li { margin-bottom: 6px; }
.bg-hint { font-size: 13px; color: var(--ink-500); margin: 10px 0 0; }
.bg-url {
  font-family: var(--mono); font-size: 12px; word-break: break-all;
  background: var(--paper-1); border: 1px solid var(--border); border-radius: var(--radius-base);
  padding: 8px 10px; margin: 14px 0 0; color: var(--ink-700);
}
.browser-gate .btn { margin-bottom: 10px; }

/* ===== Popup ban Source ===== */
.src-pop { max-width: 420px; text-align: center; }
.src-badge {
  display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700;
  background: var(--purple); border: 1px solid var(--border); border-radius: var(--radius-base);
  box-shadow: var(--shadow-sm); padding: 4px 12px; margin-bottom: 12px;
}
.src-pop h3 { font-size: 21px; margin-bottom: 6px; padding-right: 40px; }
.src-lead { font-size: 15px; color: var(--ink-700); margin: 0 0 16px; }
.src-zalo {
  display: flex; align-items: center; gap: 12px; text-decoration: none;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-base);
  box-shadow: var(--shadow); padding: 12px 14px; transition: transform .12s, box-shadow .12s;
}
.src-zalo:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow-lg); }
.src-zalo:active { transform: translate(2px, 2px); box-shadow: var(--shadow-sm); }
.zalo-logo {
  flex: 0 0 auto; display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--shadow-sm);
  padding: 3px; background: #fff; line-height: 0;
}
.zalo-logo svg { display: block; border-radius: 8px; }
.zalo-num { flex: 1 1 auto; text-align: left; font-size: 19px; font-weight: 700; color: var(--ink-900); }
.src-zalo-go { color: var(--ink-500); font-size: 15px; }
.src-mute {
  display: flex; align-items: center; gap: 8px; justify-content: flex-start;
  margin: 16px 2px 0; font-size: 14px; font-weight: 700; color: var(--ink-700); cursor: pointer;
}
.src-mute input { width: 18px; height: 18px; accent-color: var(--ink-900); cursor: pointer; }

/* ===== Animations (Animate UI Tokens & Curves) ===== */
@keyframes fadeInUp {
  from { opacity: 0; filter: blur(2px); transform: translateY(14px); }
  to { opacity: 1; filter: blur(0px); transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes slideInRight {
  from { opacity: 0; filter: blur(4px); transform: translateX(36px) scale(0.96); }
  to { opacity: 1; filter: blur(0px); transform: translateX(0) scale(1); }
}
@keyframes slideOutRight {
  from { opacity: 1; filter: blur(0px); transform: translateX(0) scale(1); }
  to { opacity: 0; filter: blur(2px); transform: translateX(40px) scale(0.95); }
}
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes scaleIn {
  from { opacity: 0; filter: blur(3px); transform: scale(var(--scale-modal)); }
  to { opacity: 1; filter: blur(0px); transform: scale(1); }
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .5; }
}

.animate-fade-in-up { animation: fadeInUp 0.35s var(--ease-out) both; will-change: transform, opacity; }
.animate-fade-in { animation: fadeIn 0.25s var(--ease-color) both; }
.animate-scale-in { animation: scaleIn 0.3s var(--ease-drawer) both; will-change: transform, opacity; }

.admin-card { animation: fadeInUp 0.35s var(--ease-out) both; will-change: transform, opacity; }

.tab {
  transition: background 0.16s var(--ease-color), color 0.16s var(--ease-color), transform 0.14s var(--ease-out), box-shadow 0.14s var(--ease-color);
  touch-action: manipulation;
  will-change: transform;
}
.tab:hover { transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.tab:active { transform: translateY(1px) scale(var(--scale-press)); box-shadow: none; }

.kpi {
  transition: transform 0.2s var(--ease-out), box-shadow 0.2s var(--ease-color);
  touch-action: manipulation;
  will-change: transform, box-shadow;
}
.kpi:hover { transform: translate(-3px, -3px); box-shadow: var(--shadow-lg); }
.kpi:active { transform: translate(0, 0) scale(var(--scale-choice)); box-shadow: var(--shadow-sm); }

/* ===== Toast (Animate UI Slide & Dismiss Curves) ===== */
.toast-container { position: fixed; top: 80px; right: 16px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast-item {
  pointer-events: auto; display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  min-width: 280px; max-width: 400px; background: var(--paper-0); border: 1px solid var(--border);
  border-radius: var(--radius-base); box-shadow: var(--shadow); font-family: var(--font-itim); font-size: 14px;
  animation: slideInRight 0.35s var(--ease-out) both;
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  will-change: transform, opacity;
}
.toast-item.removing { animation: slideOutRight 0.2s var(--ease-away) both; }
.toast-item.success { border-left: 4px solid var(--green); }
.toast-item.error { border-left: 4px solid var(--red); }
.toast-item.info { border-left: 4px solid var(--blue); }
.toast-icon { font-size: 16px; flex-shrink: 0; }
.toast-msg { flex: 1; }
.toast-close {
  background: none; border: none; cursor: pointer; font-size: 14px; color: var(--ink-500); padding: 2px 6px;
  transition: color 0.14s var(--ease-color), transform 0.12s var(--ease-out);
}
.toast-close:hover { color: var(--ink-900); transform: scale(1.15); }
.toast-close:active { transform: scale(var(--scale-press)); }

/* ===== Skeleton ===== */
.skeleton {
  background: linear-gradient(90deg, var(--ink-300) 25%, var(--paper-1) 50%, var(--ink-300) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.8s var(--ease-out) infinite;
  border-radius: var(--radius-base);
  will-change: background-position;
}
.skeleton-text { height: 16px; margin-bottom: 8px; }
.skeleton-title { height: 24px; width: 60%; margin-bottom: 12px; }
.skeleton-card { height: 120px; }
.skeleton-row { height: 40px; margin-bottom: 6px; }
.skeleton-kpi { height: 80px; border-radius: 12px; }

/* Animate UI Reduced Motion Standards */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
  .modal, .modal-back, .toast-item, .admin-card, .btn, .tab, .kpi, .plan {
    animation: none !important;
    transform: none !important;
    filter: none !important;
  }
}


