* { box-sizing: border-box; }
html,
body {
  font-family: var(--vx-font);
  color: var(--vx-text);
  background: var(--vx-bg);
  margin: 0;
  line-height: 1.5;
}
a { color: var(--vx-primary); text-decoration: none; }
a:hover { color: var(--vx-primary-hover); }

/* App shell */
.vx-app { display: flex; min-height: 100vh; }
.vx-sidebar {
  width: var(--vx-sidebar-width);
  background: var(--vx-sidebar-bg);
  border-right: 1px solid var(--vx-border);
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 1000;
  transition: transform 0.25s ease, width 0.25s ease;
}
.vx-main-wrap {
  flex: 1;
  margin-left: var(--vx-sidebar-width);
  min-width: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--vx-bg);
}
.vx-topbar {
  height: var(--vx-topbar-height);
  background: var(--vx-surface);
  border-bottom: 1px solid var(--vx-border);
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 100;
}
.vx-content {
  padding: 1.5rem;
  flex: 1;
  background: var(--vx-bg);
}

/* Logo */
.vx-logo {
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--vx-primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  padding: 0 0.5rem;
}
.vx-logo-icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--vx-primary), var(--vx-accent-pink));
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1rem;
  flex-shrink: 0;
}
.vx-logo-img {
  max-height: 36px;
  max-width: 160px;
  width: auto;
  height: auto;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 10px;
}
.vx-auth-page .vx-logo {
  justify-content: center;
}

.vx-sidebar-wallet {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem 0.75rem;
  align-items: stretch;
  background: var(--vx-surface);
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  padding: 0.7rem 0.85rem;
  margin-bottom: 1rem;
  line-height: 1.35;
  box-shadow: var(--vx-shadow-sm);
  cursor: default;
  user-select: none;
}
.vx-sidebar-wallet-col {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}
.vx-sidebar-wallet-col--end {
  text-align: right;
  flex-shrink: 0;
}
.vx-sidebar-wallet-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--vx-muted);
}
.vx-sidebar-wallet-balance {
  font-size: clamp(0.78rem, 3.2vw, 0.92rem);
  font-weight: 800;
  color: var(--vx-primary);
  font-variant-numeric: tabular-nums;
  line-height: 1.25;
  word-break: break-word;
}
.vx-sidebar-wallet-discount {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--vx-accent-pink);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* Nav */
.vx-nav { list-style: none; padding: 0; margin: 0; flex: 1; }
.vx-nav-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--vx-muted);
  padding: 0.75rem 0.75rem 0.35rem;
  font-weight: 600;
}
.vx-nav a {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--vx-radius-md);
  color: var(--vx-text);
  font-weight: 500;
  font-size: 0.9rem;
  margin-bottom: 2px;
  transition: background 0.15s, color 0.15s;
}
.vx-nav a:hover { background: rgba(108, 92, 231, 0.08); color: var(--vx-primary); }
.vx-nav a.active {
  background: var(--vx-primary-soft);
  color: var(--vx-primary);
}
.vx-nav a i { font-size: 1.1rem; width: 1.25rem; text-align: center; }
.vx-nav-footer {
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--vx-border);
}
.vx-client-page > .vx-grid-2,
.vx-client-page > .vx-grid-3,
.vx-client-page > .vx-grid-4,
.vx-client-page > .vx-card {
  margin-bottom: 0;
}
.vx-client-page > * + * {
  margin-top: 1rem;
}
.vx-nav-logout { color: var(--vx-accent-red) !important; }
.vx-nav-logout:hover { background: rgba(255, 118, 117, 0.1) !important; }

/* Topbar */
.vx-topbar-title { font-weight: 700; font-size: 1.15rem; flex: 1; }
.vx-search {
  flex: 0 1 280px;
  position: relative;
}
.vx-search input {
  width: 100%;
  padding: 0.5rem 1rem 0.5rem 2.25rem;
  border: none;
  background: var(--vx-bg);
  border-radius: var(--vx-radius-md);
  font-size: 0.875rem;
}
.vx-search i {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--vx-muted);
}
.vx-topbar-actions { display: flex; align-items: center; gap: 0.75rem; }
.vx-icon-btn {
  width: 40px; height: 40px;
  border: none; background: var(--vx-bg);
  border-radius: var(--vx-radius-md);
  display: flex; align-items: center; justify-content: center;
  color: var(--vx-muted);
  cursor: pointer;
  position: relative;
}
.vx-icon-btn:hover { background: var(--vx-primary-soft); color: var(--vx-primary); }
.vx-badge-dot {
  position: absolute; top: 6px; right: 6px;
  width: 8px; height: 8px;
  background: var(--vx-accent-red);
  border-radius: 50%;
  border: 2px solid var(--vx-surface);
}
.vx-user-menu {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.35rem 0.5rem 0.35rem 0.35rem;
  border-radius: var(--vx-radius-md);
  cursor: pointer;
  border: none;
  background: transparent;
  font-family: inherit;
}
.vx-user-menu:hover { background: var(--vx-bg); }
.vx-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--vx-primary), #a29bfe);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 600; font-size: 0.85rem;
}
.vx-dropdown {
  position: absolute;
  right: 1.5rem;
  top: calc(var(--vx-topbar-height) - 4px);
  background: var(--vx-surface);
  border-radius: var(--vx-radius-md);
  box-shadow: var(--vx-shadow);
  min-width: 180px;
  padding: 0.5rem;
  display: none;
  z-index: 200;
}
.vx-dropdown.show { display: block; }
.vx-dropdown a, .vx-dropdown button {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  text-align: left;
  padding: 0.5rem 0.75rem;
  border: none;
  background: none;
  border-radius: var(--vx-radius-sm);
  font-size: 0.875rem;
  color: var(--vx-text);
  cursor: pointer;
  font-family: inherit;
  text-decoration: none;
}
.vx-dropdown a:hover, .vx-dropdown button:hover { background: var(--vx-bg); }
.vx-dropdown-sep {
  border: none;
  border-top: 1px solid var(--vx-border);
  margin: 0.35rem 0;
}

/* Cards */
.vx-card {
  background: var(--vx-surface);
  border-radius: var(--vx-radius-lg);
  box-shadow: var(--vx-shadow-sm);
  border: 1px solid var(--vx-border);
  overflow: hidden;
}
.vx-card-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--vx-border);
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.vx-card-body { padding: 1.25rem; }

/* Stat card */
.vx-stat {
  background: var(--vx-surface);
  border-radius: var(--vx-radius-lg);
  padding: 1.25rem;
  box-shadow: var(--vx-shadow-sm);
  border: 1px solid var(--vx-border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.vx-stat-label { font-size: 0.8rem; color: var(--vx-muted); margin-bottom: 0.25rem; }
.vx-stat-value { font-size: 1.5rem; font-weight: 700; line-height: 1.2; }
.vx-stat-sub { font-size: 0.75rem; margin-top: 0.35rem; }
.vx-stat-icon {
  width: 48px; height: 48px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem;
  color: #fff;
  flex-shrink: 0;
}
.vx-stat-icon.purple { background: linear-gradient(135deg, var(--vx-primary), #a29bfe); }
.vx-stat-icon.pink { background: linear-gradient(135deg, var(--vx-accent-pink), #e84393); }
.vx-stat-icon.orange { background: linear-gradient(135deg, var(--vx-accent-orange), #f39c12); }
.vx-stat-icon.green { background: linear-gradient(135deg, var(--vx-accent-green), #55efc4); }
.vx-trend-up { color: var(--vx-accent-green); }
.vx-trend-down { color: var(--vx-accent-red); }

/* Buttons */
.vx-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  border-radius: var(--vx-radius-md);
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: transform 0.1s, box-shadow 0.15s;
}
.vx-btn-primary {
  background: linear-gradient(135deg, var(--vx-primary), #8B7CF6);
  color: #fff;
  box-shadow: 0 4px 14px rgba(108, 92, 231, 0.35);
}
.vx-btn-primary:hover { transform: translateY(-1px); color: #fff; }
.vx-btn-outline {
  background: transparent;
  border: 1px solid var(--vx-border);
  color: var(--vx-text);
}
.vx-btn-outline:hover { border-color: var(--vx-primary); color: var(--vx-primary); }
.vx-btn-success {
  background: linear-gradient(135deg, var(--vx-accent-green), #55efc4);
  color: #fff;
}
.vx-btn-sm { padding: 0.4rem 0.85rem; font-size: 0.8rem; }

/* Forms */
.vx-label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--vx-muted); margin-bottom: 0.35rem; }
.vx-required { color: var(--vx-accent-red); }
.vx-input, .vx-textarea, .vx-select {
  width: 100%;
  padding: 0.65rem 1rem;
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  font-family: inherit;
  font-size: 0.9rem;
  background: var(--vx-surface);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.vx-input:focus, .vx-textarea:focus, .vx-select:focus {
  outline: none;
  border-color: var(--vx-primary);
  box-shadow: 0 0 0 3px var(--vx-primary-soft);
}
.vx-input[type="number"] {
  -moz-appearance: textfield;
  appearance: textfield;
}
.vx-input[type="number"]::-webkit-outer-spin-button,
.vx-input[type="number"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.vx-select {
  padding-right: 2.25rem;
  cursor: pointer;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16' fill='%2364748b'%3E%3Cpath d='M4.5 6l3.5 3.5L11.5 6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
  background-size: 0.75rem;
}

/* Account type picker (BC / Ad Manager) */
.vx-type-picker {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}
.vx-type-picker-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1.5px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  background: var(--vx-surface);
  color: var(--vx-text);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}
.vx-type-picker-btn:hover:not(.is-active) {
  border-color: #D5D9E2;
  background: #FAFBFD;
}
.vx-type-picker-btn:focus-visible {
  outline: none;
  border-color: var(--vx-primary);
  box-shadow: 0 0 0 3px var(--vx-primary-soft);
}
.vx-type-picker-btn.is-active {
  border-color: var(--vx-primary);
  background: var(--vx-primary-soft);
  color: var(--vx-primary);
  box-shadow: var(--vx-shadow-sm);
}
.vx-type-picker-icon {
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--vx-radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  background: var(--vx-bg);
  color: var(--vx-muted);
  transition: background 0.2s ease, color 0.2s ease;
}
.vx-type-picker-btn.is-active .vx-type-picker-icon {
  background: var(--vx-surface);
  color: var(--vx-primary);
}
.vx-type-picker-label {
  line-height: 1.3;
  min-width: 0;
}

/* Table */
.vx-table-wrap { overflow-x: auto; }
.vx-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.vx-table th {
  text-align: left;
  padding: 0.75rem 1rem;
  font-weight: 600;
  color: var(--vx-muted);
  background: #FAFBFD;
  border-bottom: 1px solid var(--vx-border);
}
.vx-card .vx-table th {
  background: var(--vx-surface);
}
.vx-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--vx-border);
}
.vx-table tbody tr:hover { background: rgba(108, 92, 231, 0.03); }

/* Badges */
.vx-badge {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}
.vx-badge-success { background: rgba(0, 184, 148, 0.15); color: var(--vx-accent-green); }
.vx-badge-warning { background: rgba(253, 203, 110, 0.3); color: #d68910; }
.vx-badge-danger { background: rgba(255, 118, 117, 0.15); color: var(--vx-accent-red); }
.vx-badge-primary { background: var(--vx-primary-soft); color: var(--vx-primary); }

/* Grid */
.vx-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.vx-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.vx-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.vx-gap { gap: 1rem; }
.vx-mb { margin-bottom: 1.5rem; }
.vx-admin-section-title {
  margin: 0 0 0.75rem;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--vx-muted);
}
/* Auth / Landing */
.vx-auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--vx-bg);
  position: relative;
  overflow: hidden;
}
.vx-auth-page::before {
  content: '';
  position: absolute;
  top: -20%; right: -10%;
  width: 50%; height: 60%;
  background: linear-gradient(135deg, rgba(108,92,231,0.15), rgba(253,121,168,0.1));
  border-radius: 50%;
  filter: blur(60px);
}
.vx-auth-card {
  background: var(--vx-surface);
  border-radius: 20px;
  padding: 2rem;
  width: 100%;
  max-width: 420px;
  box-shadow: var(--vx-shadow);
  position: relative;
  z-index: 1;
}
.vx-auth-back-link {
  text-align: center;
  margin-top: 1rem;
  font-size: 0.8rem;
}
.vx-auth-back-link a {
  color: var(--vx-primary);
  font-weight: 600;
  text-decoration: none;
}
.vx-auth-back-link a:hover {
  text-decoration: underline;
}
.vx-auth-card--2fa h4,
.vx-auth-card--2fa .vx-auth-sub {
  text-align: center;
}
.vx-auth-2fa-form > div {
  margin-bottom: 1.25rem;
  text-align: center;
}
.vx-auth-2fa-form .vx-input-otp {
  display: block;
  width: 100%;
  max-width: 14rem;
  margin-left: auto;
  margin-right: auto;
}
.vx-auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.15rem 0;
  color: var(--vx-muted);
  font-size: 0.8rem;
}
.vx-auth-divider::before,
.vx-auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--vx-border);
}
.vx-btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.65rem 1rem;
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  background: var(--vx-surface);
  color: var(--vx-text);
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
.vx-btn-google:hover {
  background: #fafbfd;
  border-color: #d5d9e2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  color: var(--vx-text);
}
.vx-btn-google .bi-google {
  color: #ea4335;
  font-size: 1.05rem;
}
/* Landing — footer sát đáy viewport */
.vx-landing-html,
.vx-landing-page {
  height: 100%;
  margin: 0;
}
.vx-landing-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--vx-bg);
}
.vx-landing-nav {
  flex-shrink: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: var(--vx-surface);
  border-bottom: 1px solid var(--vx-border);
}
.vx-landing-nav-actions {
  display: flex;
  gap: 0.75rem;
}
.vx-landing-main {
  flex: 1 1 auto;
  width: 100%;
}
.vx-landing-footer {
  flex-shrink: 0;
  width: 100%;
  text-align: center;
  padding: 1rem 2rem;
  color: var(--vx-muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--vx-border);
  background: var(--vx-surface);
}
.vx-landing-hero {
  text-align: center;
  padding: 4rem 1rem 3rem;
  position: relative;
}
.vx-landing-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 50%; transform: translateX(-50%);
  width: 80%; height: 200px;
  background: linear-gradient(180deg, rgba(108,92,231,0.12), transparent);
  border-radius: 0 0 50% 50%;
}
.vx-feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
  padding: 0 1.5rem 1.5rem;
  flex: 0 0 auto;
  align-items: start;
}
.vx-feature-grid .vx-card {
  height: auto;
  align-self: start;
}
.vx-feature-grid .vx-card-body {
  padding: 1.35rem 1.15rem;
}
@media (max-width: 991px) {
  .vx-landing-nav { padding: 1rem 1.25rem; }
  .vx-feature-grid { grid-template-columns: 1fr; max-width: 400px; }
}

/* Toast — góc phải, ngay dưới topbar */
.vx-toast-wrap {
  position: fixed;
  top: calc(var(--vx-topbar-height) + 0.75rem);
  right: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: flex-end;
  pointer-events: none;
  max-width: min(360px, calc(100vw - 2rem));
}
.vx-toast {
  padding: 0.85rem 1rem;
  border-radius: var(--vx-radius-md);
  background: var(--vx-surface);
  color: var(--vx-text);
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.4;
  border: 1px solid var(--vx-border);
  border-left: 4px solid var(--vx-primary);
  box-shadow: var(--vx-shadow);
  animation: vxToastIn 0.3s ease;
  pointer-events: auto;
}
.vx-toast.success {
  border-color: rgba(108, 92, 231, 0.25);
  border-left-color: var(--vx-primary);
}
.vx-toast.error {
  border-color: rgba(255, 118, 117, 0.35);
  border-left-color: var(--vx-accent-red);
}
@keyframes vxToastIn {
  from { transform: translateY(-12px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* Alert flash */
.vx-alert {
  padding: 0.85rem 1rem;
  border-radius: var(--vx-radius-md);
  margin-bottom: 1rem;
  font-size: 0.875rem;
}
.vx-alert-success { background: rgba(0, 184, 148, 0.12); color: var(--vx-accent-green); border: 1px solid rgba(0, 184, 148, 0.3); }
.vx-alert-info { background: rgba(91, 75, 212, 0.08); color: var(--vx-primary); border: 1px solid rgba(91, 75, 212, 0.2); }

/* History list */
.vx-history-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0;
  border-bottom: 1px solid var(--vx-border);
}
.vx-history-item:last-child { border-bottom: none; }
.vx-history-viewable {
  cursor: pointer;
  border-radius: var(--vx-radius-sm);
  margin: 0 -0.35rem;
  padding-left: 0.35rem !important;
  padding-right: 0.35rem !important;
  transition: background 0.15s ease;
}
.vx-history-viewable:hover {
  background: var(--vx-primary-soft);
}
.vx-history-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--vx-primary-soft);
  color: var(--vx-primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 700;
}

/* Hamburger */
.vx-menu-toggle {
  display: none;
  border: none;
  background: var(--vx-bg);
  width: 40px; height: 40px;
  border-radius: var(--vx-radius-md);
  cursor: pointer;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

/* Overlay */
.vx-sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 999;
}

/* Responsive */
@media (max-width: 1199px) {
  .vx-grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 991px) {
  .vx-sidebar {
    transform: translateX(-100%);
  }
  .vx-sidebar.open { transform: translateX(0); }
  .vx-sidebar-overlay.show { display: block; }
  .vx-main-wrap { margin-left: 0; }
  .vx-menu-toggle { display: flex; }
  .vx-search { display: none; }
  .vx-grid-3, .vx-feature-grid { grid-template-columns: 1fr; }
}
@media (max-width: 575px) {
  .vx-grid-4, .vx-grid-2 { grid-template-columns: 1fr; }
  .vx-content { padding: 1rem; }
}

/* Account area */
.vx-account-grid {
  display: grid;
  grid-template-columns: minmax(240px, 300px) 1fr;
  gap: 1.25rem;
  align-items: start;
}
.vx-account-main { min-width: 0; }
.vx-profile-card {
  background: var(--vx-surface);
  border-radius: var(--vx-radius-lg);
  border: 1px solid var(--vx-border);
  box-shadow: var(--vx-shadow-sm);
  overflow: hidden;
}
.vx-profile-card-header {
  background: linear-gradient(135deg, var(--vx-primary), #5f4fd6);
  color: #fff;
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
}
.vx-profile-card-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  border: 3px solid rgba(255,255,255,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  font-weight: 700;
}
.vx-profile-card-user strong { display: block; font-size: 1rem; }
.vx-profile-card-user span { font-size: 0.85rem; opacity: 0.9; }
.vx-profile-card-list {
  list-style: none;
  margin: 0;
  padding: 0.85rem 1rem 1rem;
}
.vx-profile-card-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.8rem;
  padding: 0.4rem 0;
  color: var(--vx-text);
  word-break: break-word;
}
.vx-profile-card-list li i { color: var(--vx-muted); margin-top: 0.1rem; }
.vx-account-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 1rem;
}
.vx-account-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.75rem;
  border-radius: var(--vx-radius-md);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--vx-muted);
  text-decoration: none;
  border: 1px solid transparent;
}
.vx-account-nav a:hover { background: var(--vx-surface); color: var(--vx-primary); }
.vx-account-nav a.is-active {
  background: var(--vx-primary-soft);
  color: var(--vx-primary);
  border-color: rgba(108, 92, 231, 0.25);
}
.vx-form-row {
  display: grid;
  grid-template-columns: minmax(120px, 180px) 1fr;
  gap: 0.75rem 1rem;
  align-items: center;
  margin-bottom: 1rem;
}
.vx-form-row-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--vx-text);
}
.vx-input-readonly {
  background: var(--vx-bg) !important;
  color: var(--vx-muted);
  cursor: default;
}
.vx-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
  padding-left: calc(minmax(120px, 180px) + 1rem);
}
.vx-form-hint {
  font-size: 0.75rem;
  color: var(--vx-muted);
  margin: 0.35rem 0 0;
}
.vx-account-stats .vx-card-body { padding: 1rem; }
.vx-amount-pos { color: #00b894; font-weight: 700; }
.vx-amount-neg { color: var(--vx-accent-red); font-weight: 700; }
.vx-amount-neutral { color: #0984e3; font-weight: 700; }
.vx-amount-warn { color: #e17055; font-weight: 700; }
.vx-account-search-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.vx-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--vx-border);
  font-size: 0.8rem;
  color: var(--vx-muted);
}
.vx-pagination-btns { display: flex; gap: 0.35rem; flex-wrap: wrap; }
.vx-totp-qr {
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  display: block;
}

.vx-totp-form {
  max-width: 640px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.vx-totp-panel {
  background: var(--vx-bg);
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  padding: 1rem 1.15rem;
}
.vx-totp-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.vx-totp-panel-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--vx-text);
}
.vx-totp-panel-hint {
  margin: 0.65rem 0 0;
  font-size: 0.78rem;
  color: var(--vx-muted);
  line-height: 1.45;
}
.vx-totp-setup-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1.25rem;
  align-items: start;
}
.vx-totp-setup-secret .vx-input-mono {
  font-family: ui-monospace, Consolas, monospace;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
}
.vx-totp-setup-qr {
  text-align: center;
}
.vx-totp-setup-qr .vx-label {
  display: block;
  margin-bottom: 0.5rem;
}
.vx-totp-verify .vx-label {
  display: block;
  margin-bottom: 0.5rem;
}
.vx-totp-verify-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}
.vx-input-otp {
  width: 10.5rem;
  max-width: 100%;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.35em;
  font-family: ui-monospace, Consolas, monospace;
}
.vx-input-otp::placeholder {
  color: var(--vx-muted);
  opacity: 0.55;
  letter-spacing: 0.35em;
  font-weight: 500;
}
.vx-totp-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-left: auto;
}
@media (max-width: 575px) {
  .vx-totp-setup-grid {
    grid-template-columns: 1fr;
  }
  .vx-totp-setup-qr {
    text-align: left;
  }
  .vx-totp-actions {
    margin-left: 0;
    width: 100%;
  }
  .vx-totp-actions .vx-btn {
    flex: 1;
  }
}

.vx-form-row-toggle {
  align-items: center;
}
.vx-form-row-toggle .vx-form-hint-below {
  grid-column: 1 / -1;
  margin: 0.15rem 0 0;
  padding-top: 0.15rem;
}
.vx-form-hint-below {
  font-size: 0.75rem;
  color: var(--vx-muted);
  line-height: 1.45;
}
.vx-toggle-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  min-height: 26px;
}
.vx-toggle-status {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--vx-muted);
}
.vx-toggle-status.is-on { color: #00b894; }
.vx-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}
.vx-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.vx-switch-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #CBD5E1;
  border-radius: 26px;
  transition: background 0.2s ease;
}
.vx-switch-slider::before {
  content: '';
  position: absolute;
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}
.vx-switch input:checked + .vx-switch-slider {
  background: var(--vx-primary);
}
.vx-switch input:checked + .vx-switch-slider::before {
  transform: translateX(22px);
}
.vx-switch input:focus-visible + .vx-switch-slider {
  outline: 2px solid var(--vx-primary);
  outline-offset: 2px;
}
@media (max-width: 991px) {
  .vx-account-grid { grid-template-columns: 1fr; }
  .vx-form-row { grid-template-columns: 1fr; }
  .vx-form-actions { padding-left: 0; }
  .vx-account-stats { grid-template-columns: 1fr !important; }
}

/* Wallet — nạp tiền */
.vx-wallet-section {
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--vx-border);
}
.vx-wallet-section:last-child {
  padding-bottom: 0;
  border-bottom: none;
}
.vx-wallet-section-title {
  margin: 0 0 0.5rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--vx-text);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.vx-wallet-section-badge {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.15rem 0.45rem;
  border-radius: var(--vx-radius-sm);
  background: var(--vx-primary-soft, #EEF2FF);
  color: var(--vx-primary);
}
.vx-modal {
  position: fixed;
  inset: 0;
  z-index: 1050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.vx-modal[hidden] {
  display: none !important;
}
.vx-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
}
.vx-modal-dialog {
  position: relative;
  width: 100%;
  max-width: 400px;
  max-height: calc(100vh - 2rem);
  overflow: auto;
  background: var(--vx-surface);
  border-radius: var(--vx-radius-md);
  box-shadow: 0 12px 40px rgba(15, 23, 42, 0.18);
}
.vx-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--vx-border);
}
.vx-modal-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}
.vx-modal-close {
  border: none;
  background: transparent;
  color: var(--vx-muted);
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
}
.vx-modal-close:hover { color: var(--vx-text); }
.vx-modal-body {
  padding: 1rem;
}
.vx-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 1rem;
}
.vx-modal-body .vx-wallet-qr-result {
  margin-top: 0;
  padding: 0;
  border: none;
  background: transparent;
}
.vx-modal-body .vx-wallet-qr-panel {
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}
.vx-modal-body .vx-wallet-qr-figure {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  padding: 0.25rem 0;
}
.vx-modal-body .vx-wallet-qr-figure .vx-wallet-qr-img {
  display: block;
  margin: 0 auto;
  max-width: 240px;
  width: auto;
  height: auto;
}
.vx-wallet-qr-details {
  width: 100%;
}
.vx-modal-body .vx-wallet-qr-details {
  max-width: 100%;
}
.vx-modal-body .vx-wallet-qr-meta li {
  display: grid;
  grid-template-columns: 5.25rem 1fr;
  gap: 0.35rem 0.75rem;
  justify-content: start;
  align-items: baseline;
}
.vx-modal-body .vx-wallet-qr-meta li span {
  text-align: left;
}
.vx-modal-body .vx-wallet-qr-meta li strong {
  text-align: right;
  word-break: break-word;
}
.vx-invoice-code-box {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border-radius: var(--vx-radius-md);
  background: #FFF5F5;
  border: 1px solid #FECACA;
}
.vx-invoice-code-label {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--vx-muted);
  margin-bottom: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.vx-invoice-code-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.vx-invoice-code-value {
  flex: 1;
  min-width: 0;
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--vx-accent-red);
  padding: 0.4rem 0.55rem;
  background: #fff;
  border-radius: var(--vx-radius-sm);
  word-break: break-all;
}
.vx-invoice-code-hint {
  margin: 0.45rem 0 0;
  font-size: 0.72rem;
  color: var(--vx-muted);
}
.vx-copy-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  border: 1px solid var(--vx-border);
  background: #fff;
  color: var(--vx-text);
  border-radius: var(--vx-radius-sm);
  padding: 0.25rem 0.45rem;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  flex-shrink: 0;
}
.vx-copy-chip:hover {
  border-color: var(--vx-primary);
  color: var(--vx-primary);
}
.vx-copy-chip.is-copied {
  border-color: #22c55e;
  color: #15803d;
  background: #f0fdf4;
}
.vx-copy-chip--lg {
  padding: 0.4rem 0.65rem;
}
.vx-copy-chip--lg span {
  display: inline;
}
.vx-wallet-pending-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.vx-wallet-pending-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  background: #FFFBEB;
  border-color: #FDE68A;
}
.vx-wallet-pending-head {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.vx-wallet-pending-code {
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--vx-accent-red);
}
.vx-wallet-pending-meta {
  margin: 0.2rem 0 0;
  font-size: 0.78rem;
  color: var(--vx-muted);
}

/* Nạp theo nội dung CK — layout gọn */
.vx-wallet-content-wrap {
  max-width: 40rem;
}
.vx-wallet-content-hero {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  border: 1px solid #FECACA;
  border-radius: var(--vx-radius-md);
  background: linear-gradient(135deg, #FFF5F5 0%, #FFFBEB 100%);
}
.vx-wallet-content-hero-title {
  margin: 0 0 0.2rem;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--vx-text);
}
.vx-wallet-content-required {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--vx-accent-red);
}
.vx-wallet-content-hero-desc {
  margin: 0;
  font-size: 0.78rem;
  color: var(--vx-muted);
  line-height: 1.45;
  max-width: 22rem;
}
.vx-wallet-content-hero-code {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.vx-wallet-content-hero-code code {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--vx-accent-red);
  letter-spacing: 0.04em;
  padding: 0.35rem 0.65rem;
  background: #fff;
  border-radius: var(--vx-radius-sm);
  border: 1px dashed #F87171;
}
.vx-wallet-bank-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
}
.vx-wallet-bank-switch-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.65rem;
  border: 1px solid var(--vx-border);
  border-radius: 999px;
  background: var(--vx-surface);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--vx-text);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.vx-wallet-bank-switch-btn img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}
.vx-wallet-bank-switch-btn.is-active {
  border-color: var(--vx-primary);
  background: var(--vx-primary-soft, #EEF2FF);
  color: var(--vx-primary);
}
.vx-wallet-pay-panels {
  position: relative;
}
.vx-wallet-pay-card {
  display: none;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  background: var(--vx-surface);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}
.vx-wallet-pay-card.is-active {
  display: flex;
}
.vx-wallet-pay-card[hidden] {
  display: none !important;
}
.vx-wallet-pay-info {
  flex: 1;
  min-width: 0;
}
.vx-wallet-pay-logo {
  max-width: 100px;
  max-height: 40px;
  object-fit: contain;
  margin-bottom: 0.65rem;
}
.vx-wallet-pay-facts {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.vx-wallet-pay-fact {
  display: grid;
  grid-template-columns: 4.5rem 1fr auto;
  gap: 0.35rem 0.5rem;
  align-items: center;
  font-size: 0.84rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--vx-border);
}
.vx-wallet-pay-fact:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.vx-wallet-pay-fact dt {
  margin: 0;
  color: var(--vx-muted);
  font-weight: 500;
}
.vx-wallet-pay-fact dd {
  margin: 0;
  font-weight: 700;
  color: var(--vx-text);
  word-break: break-all;
}
.vx-wallet-pay-fact--wide dd {
  grid-column: 2 / -1;
}
.vx-wallet-pay-action {
  padding: 0;
}
.vx-wallet-pay-action .vx-btn {
  padding: 0.2rem 0.45rem;
  min-height: auto;
}
.vx-wallet-pay-qr {
  flex: 0 0 168px;
  text-align: center;
}
.vx-wallet-pay-qr .vx-wallet-qr-img {
  max-width: 168px;
  width: 100%;
}
.vx-wallet-pay-qr-caption {
  margin: 0.4rem 0 0;
  font-size: 0.7rem;
  color: var(--vx-muted);
  line-height: 1.35;
}
.vx-wallet-content-foot {
  margin: 0.85rem 0 0;
  font-size: 0.78rem;
  color: var(--vx-muted);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
@media (max-width: 520px) {
  .vx-wallet-content-hero {
    flex-direction: column;
  }
  .vx-wallet-pay-card.is-active {
    flex-direction: column;
  }
  .vx-wallet-pay-qr {
    flex: none;
    width: 100%;
    max-width: 200px;
    margin: 0 auto;
  }
}
.vx-wallet-bank-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.65rem;
  margin-bottom: 0.25rem;
}
.vx-wallet-bank-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 0.75rem 0.5rem;
  border: 2px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  background: var(--vx-surface);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  text-align: center;
}
.vx-wallet-bank-card:hover {
  border-color: #C4B5FD;
  background: #FAFAFF;
}
.vx-wallet-bank-card.is-selected {
  border-color: var(--vx-primary);
  background: #F5F3FF;
  box-shadow: 0 0 0 1px rgba(91, 75, 212, 0.2);
}
.vx-wallet-bank-card img {
  max-width: 80px;
  max-height: 40px;
  object-fit: contain;
}
.vx-wallet-bank-name {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--vx-text);
}
.vx-wallet-bank-stk {
  font-size: 0.72rem;
  color: var(--vx-muted);
}
.vx-wallet-qr-result {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid var(--vx-border);
  border-radius: var(--vx-radius-md);
  background: var(--vx-bg);
}
.vx-wallet-qr-result[hidden] { display: none !important; }
.vx-wallet-qr-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: flex-start;
}
.vx-wallet-qr-img {
  max-width: 280px;
  width: 100%;
  height: auto;
  border-radius: var(--vx-radius-sm);
  background: #fff;
}
.vx-wallet-qr-meta {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.85rem;
  flex: 1;
  min-width: 200px;
}
.vx-wallet-qr-meta li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--vx-border);
}
.vx-wallet-qr-meta li:last-child { border-bottom: none; }
.vx-wallet-qr-meta span { color: var(--vx-muted); }
