:root {
  --bg: #f1f5f9;
  --card: #fff;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --primary: #2563eb;
  --ok: #16a34a;
  --danger: #dc2626;
  --warn: #d97706;
  --side: #0b1220;
  --radius: 12px;
  --shadow: 0 8px 24px rgba(15, 23, 42, 0.07);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.45;
}
[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; }
img, video { max-width: 100%; }

/* Login — gọn · đẹp · chỉ brand + Google */
.login {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
  overflow: hidden;
  background: #0a0a0e;
}
.login-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(255, 77, 154, 0.28), transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 80%, rgba(99, 102, 241, 0.22), transparent 50%),
    radial-gradient(ellipse 40% 35% at 0% 70%, rgba(61, 220, 176, 0.12), transparent 45%),
    linear-gradient(165deg, #0a0a0e 0%, #12121a 45%, #0d0d14 100%);
}
.login-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(48px);
  opacity: 0.55;
  animation: login-float 12s ease-in-out infinite;
}
.login-orb-a {
  width: 220px; height: 220px;
  left: 12%; top: 18%;
  background: rgba(255, 77, 154, 0.35);
}
.login-orb-b {
  width: 280px; height: 280px;
  right: 8%; bottom: 12%;
  background: rgba(99, 102, 241, 0.3);
  animation-delay: -4s;
}
.login-orb-c {
  width: 160px; height: 160px;
  left: 45%; bottom: 28%;
  background: rgba(61, 220, 176, 0.18);
  animation-delay: -7s;
}
@keyframes login-float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(12px, -18px) scale(1.06); }
}
.login-card {
  position: relative;
  z-index: 1;
  width: min(380px, 100%);
  padding: 40px 32px 36px;
  text-align: center;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}
.login-logo {
  width: 72px;
  height: 72px;
  margin: 0 auto 18px;
  border-radius: 22px;
  background: linear-gradient(145deg, #ff4d9a 0%, #c026d3 48%, #6366f1 100%);
  color: #fff;
  font-weight: 900;
  font-size: 28px;
  letter-spacing: -0.04em;
  display: grid;
  place-items: center;
  box-shadow:
    0 12px 32px rgba(255, 77, 154, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.15) inset;
}
.login-title {
  margin: 0 0 28px;
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #fff;
  line-height: 1.2;
}
.btn-google {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 14px 18px;
  border: 0;
  border-radius: 14px;
  background: #fff;
  color: #1f2937;
  font-size: 15.5px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}
.btn-google:hover {
  filter: brightness(1.02);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
  transform: translateY(-1px);
}
.btn-google:active {
  transform: translateY(0);
  filter: brightness(0.98);
}
.btn-google-icon {
  flex-shrink: 0;
}
.login-error {
  margin: 16px 0 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(220, 38, 38, 0.15);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fecaca;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.35;
}
/* legacy class still used by app.js toast err on login */
.login .toast.err {
  margin: 16px 0 0;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(220, 38, 38, 0.15);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fecaca;
  font-size: 13.5px;
  font-weight: 600;
}

/* Layout */
.layout { display: grid; grid-template-columns: 260px 1fr; min-height: 100vh; }
@media (max-width: 960px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: sticky; top: 0; z-index: 40; max-height: none; }
  .nav { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; max-height: 42vh; }
  .nav-group { grid-column: 1 / -1; }
}
.sidebar {
  background: var(--side); color: #e2e8f0; padding: 14px 10px 16px;
  display: flex; flex-direction: column; gap: 8px;
}
.brand { display: flex; gap: 10px; align-items: center; padding: 4px 8px 8px; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px;
  background: linear-gradient(135deg, #f472b6, #6366f1);
  display: grid; place-items: center; font-weight: 900;
}
.brand strong { display: block; font-size: 14px; }
.brand small { color: #94a3b8; font-size: 11px; word-break: break-all; }
.side-search input {
  width: 100%; border: 1px solid #1e293b; background: #111827; color: #e2e8f0;
  border-radius: 10px; padding: 9px 11px; font-size: 13px;
}
.nav {
  flex: 1; overflow: auto; display: flex; flex-direction: column; gap: 2px;
  max-height: calc(100vh - 160px); padding-right: 2px;
}
.nav-group {
  font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: #64748b; padding: 12px 10px 4px;
}
.nav-btn {
  border: 0; background: transparent; color: #cbd5e1; text-align: left;
  padding: 9px 11px; border-radius: 10px; font-weight: 650; font-size: 13px; cursor: pointer;
}
.nav-btn:hover { background: #1e293b; color: #fff; }
.nav-btn.active { background: var(--primary); color: #fff; }
.logout { margin-top: auto; }

.main { padding: 16px 18px 48px; max-width: 1280px; }
.topbar {
  display: flex; justify-content: space-between; gap: 12px; align-items: flex-start;
  margin-bottom: 14px; flex-wrap: wrap;
}
.topbar h1 { margin: 0; font-size: 24px; }
.sub { margin: 4px 0 0; color: var(--muted); font-size: 13.5px; }
.top-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.pill {
  background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0;
  padding: 6px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700;
}
.pill.warn { background: #fff7ed; color: #c2410c; border-color: #fed7aa; }

/* Buttons / forms */
.btn {
  border: 1px solid #cbd5e1; background: #f8fafc; color: var(--ink);
  border-radius: 10px; padding: 9px 12px; font-weight: 750; cursor: pointer;
}
.btn:hover { filter: brightness(.98); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--primary); color: #fff; border-color: #1d4ed8; }
.btn-ok { background: var(--ok); color: #fff; border-color: #15803d; }
.btn-danger { background: var(--danger); color: #fff; border-color: #b91c1c; }
.btn-warn { background: #f59e0b; color: #111; border-color: #d97706; }
.btn-ghost { background: #1e293b; color: #e2e8f0; border-color: #334155; }
.btn-xl { width: 100%; padding: 14px; font-size: 16px; }
.btn-sm { padding: 6px 9px; font-size: 12px; }
.btn-icon { padding: 7px 9px; min-width: 36px; }

/* Tặng SVIP theo ID */
.vip-grant-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 14px;
  align-items: start;
}
@media (max-width: 960px) {
  .vip-grant-grid { grid-template-columns: 1fr; }
}
.vip-grant-card { max-width: none; }
.vip-grant-user {
  padding: 10px 12px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid var(--line);
  margin-bottom: 4px;
}
.svip-tier-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.svip-tier-btn {
  min-width: 58px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1.5px solid color-mix(in srgb, var(--c) 45%, #cbd5e1);
  background: var(--bg);
  color: var(--c);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transition: box-shadow .15s, transform .12s, border-color .15s;
}
.svip-tier-btn b { font-size: 15px; line-height: 1; }
.svip-tier-btn span { font-size: 10px; font-weight: 700; opacity: .85; }
.svip-tier-btn.on {
  border-color: var(--c);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--c) 28%, transparent);
  transform: translateY(-1px);
}
.svip-id-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px 3px 6px;
  border-radius: 99px;
  background: var(--bg);
  border: 1.1px solid color-mix(in srgb, var(--c) 55%, transparent);
  color: var(--c);
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.2px;
  vertical-align: middle;
}
.svip-id-dot {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  font-size: 9px;
  font-weight: 900;
  color: #fff;
  background: var(--c);
  line-height: 1;
}
.svip-id-text { color: var(--c); }
.svip-preview-list { display: flex; flex-direction: column; gap: 8px; }
.svip-preview-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.vip-grant-preview {
  padding: 10px 12px;
  border-radius: 10px;
  background: #0b1220;
  color: #e2e8f0 !important;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.vip-grant-preview .svip-id-chip { font-size: 13px; }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px; margin: 0 0 12px; box-shadow: var(--shadow);
}
.help {
  background: #eff6ff; border: 1px solid #bfdbfe; color: #1e3a8a;
  border-radius: 12px; padding: 11px 13px; margin-bottom: 12px; font-size: 13.5px;
}
.toolbar {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  margin-bottom: 10px;
}
.toolbar .grow { flex: 1; min-width: 160px; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
@media (max-width: 800px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}
label.lbl { display: block; font-size: 12.5px; font-weight: 700; margin: 0 0 5px; color: #334155; }
input[type="text"], input[type="number"], input[type="email"], input[type="search"],
input[type="url"], input[type="date"], input[type="file"], select, textarea {
  width: 100%; padding: 10px 12px; border: 1px solid #cbd5e1; border-radius: 10px; background: #fff;
}
textarea { min-height: 80px; resize: vertical; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 650; cursor: pointer; }
.muted { color: var(--muted); font-size: 13px; }
.tiny { font-size: 11px; word-break: break-all; }

/* Stats */
.stat-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px; margin-bottom: 12px;
}
.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: 12px;
  padding: 14px; text-align: center; box-shadow: var(--shadow);
}
.stat-n { font-size: 24px; font-weight: 900; color: #1d4ed8; }
.stat-l { font-size: 12px; color: var(--muted); margin-top: 3px; }

/* Table */
.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
table.data { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 720px; }
table.data th, table.data td { padding: 10px 11px; border-bottom: 1px solid #f1f5f9; text-align: left; vertical-align: middle; }
table.data th { background: #f8fafc; font-weight: 800; position: sticky; top: 0; z-index: 1; }
table.data tr:hover td { background: #fafbff; }
table.data tr.dim td { opacity: .55; }
.thumb {
  width: 44px; height: 44px; border-radius: 10px; object-fit: cover; background: #1e1b4b;
  display: grid; place-items: center; font-size: 20px; overflow: hidden;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.badge {
  display: inline-block; font-size: 10px; font-weight: 800; padding: 2px 7px;
  border-radius: 99px; background: #e2e8f0; color: #334155; margin-right: 4px;
}
.badge.on { background: #dcfce7; color: #166534; }
.badge.off { background: #f1f5f9; color: #64748b; }
.badge.hot { background: #ffedd5; color: #c2410c; }
.actions { display: flex; flex-wrap: wrap; gap: 5px; }

/* Pagination */
.pager {
  display: flex; gap: 8px; align-items: center; justify-content: space-between;
  margin-top: 10px; flex-wrap: wrap;
}
.pager .pages { display: flex; gap: 4px; flex-wrap: wrap; }

/* Preview boards */
.preview-boards {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px;
}
.pboard {
  border-radius: 10px; min-height: 110px; display: grid; place-items: center;
  border: 1px solid var(--line); overflow: hidden; position: relative;
}
.pboard span {
  position: absolute; top: 4px; left: 6px; font-size: 10px; font-weight: 800;
  background: rgba(0,0,0,.45); color: #fff; padding: 1px 6px; border-radius: 99px;
}
.pboard img, .pboard video { max-width: 90%; max-height: 90px; object-fit: contain; }
.pboard.white { background: #fff; }
.pboard.black { background: #0f172a; }
.pboard.gray { background: #94a3b8; }
.pboard.blue { background: #1d4ed8; }

/* Gift icon: ô caro = đã xóa nền (không phải xem 4 màu) */
.gift-icon-preview-wrap { margin: 4px 0 10px; }
.gift-icon-preview {
  width: min(220px, 100%);
  height: 220px;
  border-radius: 14px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  overflow: hidden;
  background-color: #e5e7eb;
  background-image:
    linear-gradient(45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(-45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #cbd5e1 75%),
    linear-gradient(-45deg, transparent 75%, #cbd5e1 75%);
  background-size: 16px 16px;
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
}
.gift-icon-preview img {
  max-width: 88%;
  max-height: 88%;
  object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,.18));
}
.gift-icon-preview.empty {
  font-size: 48px;
  color: #64748b;
}

/* Asset grid */
.asset-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px;
}
.asset-card {
  background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden;
  box-shadow: var(--shadow); display: flex; flex-direction: column;
}
.asset-card .prev {
  height: 120px; background: #0f172a; display: grid; place-items: center; position: relative;
}
.asset-card .prev img, .asset-card .prev video { max-width: 100%; max-height: 120px; object-fit: contain; }
.asset-card .meta { padding: 8px; font-size: 12px; flex: 1; }
.asset-card .meta b { display: block; font-size: 12.5px; }
.asset-card .foot { display: flex; gap: 4px; padding: 0 8px 8px; flex-wrap: wrap; }

/* Charts simple */
.chart {
  height: 160px; display: flex; align-items: flex-end; gap: 6px; padding: 10px 4px 0;
}
.chart .bar {
  flex: 1; background: linear-gradient(180deg, #60a5fa, #2563eb);
  border-radius: 6px 6px 0 0; min-width: 8px; position: relative;
}
.chart .bar span {
  position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%);
  font-size: 10px; color: var(--muted); white-space: nowrap;
}

/* Modal */
.modal { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 16px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(15,23,42,.55); }
.modal-card {
  position: relative; width: min(760px, 100%); max-height: 90vh; overflow: auto;
  background: #fff; border-radius: 16px; box-shadow: 0 24px 60px rgba(0,0,0,.3);
}
.modal-card.modal-wide {
  width: min(920px, 100%);
}
.modal-card.modal-phone {
  width: min(420px, 100%);
}
.modal-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 16px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; z-index: 2;
}
.modal-head h2 { margin: 0; font-size: 17px; }
.modal-body { padding: 14px 16px; }
.modal-foot {
  display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap;
  padding: 12px 16px; border-top: 1px solid var(--line); position: sticky; bottom: 0; background: #fff;
}

/* Phone frame · xem SVGA / video (giống Bigo admin) */
.phone-frame {
  margin: 0 auto;
  width: min(320px, 100%);
  background: #111;
  border-radius: 22px;
  padding: 10px;
  box-shadow: 0 12px 40px rgba(0,0,0,.35);
}
.phone-screen {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  max-height: min(70vh, 560px);
  background: #000;
  border-radius: 14px;
  overflow: hidden;
  display: grid;
  place-items: center;
}
.phone-screen video,
.phone-screen img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}
.svga-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at center, #1a1030 0%, #050508 70%);
}
.svga-wrap canvas {
  width: 100% !important;
  height: 100% !important;
  max-width: 100%;
  max-height: 100%;
}
.svga-status {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #e2e8f0;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  padding: 16px;
  background: rgba(0,0,0,.35);
}
.svga-status.err { color: #fecaca; }

.thumb-click {
  cursor: pointer;
  outline: 2px solid transparent;
  transition: outline-color .15s;
}
.thumb-click:hover { outline-color: #3b82f6; }
.thumb-svga {
  display: grid; place-items: center;
  width: 48px; height: 48px;
  background: linear-gradient(135deg, #7c3aed, #db2777);
  color: #fff; font-size: 10px; font-weight: 900;
  border-radius: 10px; letter-spacing: .02em;
}
a.link-svga {
  color: #2563eb;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
}
a.link-svga:hover { text-decoration: underline; }
a.link-svga.muted { color: #64748b; }

/* Drop zone */
.drop {
  border: 2px dashed #93c5fd; background: #f8fbff; border-radius: 12px;
  padding: 16px; text-align: center; cursor: pointer; margin-bottom: 10px;
}
.drop.over { border-color: #2563eb; background: #eff6ff; }
.drop strong { display: block; margin-bottom: 4px; }
.file-list { font-size: 12px; color: #0369a1; margin-top: 6px; text-align: left; }

.toast-global {
  position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%);
  background: #0f172a; color: #fff; padding: 11px 16px; border-radius: 999px;
  font-weight: 700; z-index: 200; box-shadow: 0 12px 30px rgba(0,0,0,.3); max-width: 92vw;
}
.toast-global.err { background: #b91c1c; }
.toast { margin: 8px 0 0; font-weight: 750; color: #047857; font-size: 13.5px; }
.toast.err { color: #b91c1c; }

.tabs-mini { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.tabs-mini button.active { background: var(--primary); color: #fff; border-color: #1d4ed8; }

.form-section { margin: 12px 0; padding-top: 8px; border-top: 1px solid #f1f5f9; }
.form-section h4 { margin: 0 0 8px; font-size: 13px; color: #1e40af; }

.empty {
  text-align: center; padding: 28px 12px; color: var(--muted);
  background: #fff; border: 1px dashed var(--line); border-radius: 12px;
}

.top-list { list-style: none; padding: 0; margin: 0; }
.top-list li {
  display: flex; justify-content: space-between; gap: 8px;
  padding: 8px 0; border-bottom: 1px solid #f1f5f9; font-size: 13.5px;
}
.top-list .rank { font-weight: 900; color: #1d4ed8; width: 28px; }

/* ---------------------------------------------------
   GIFT STUDIO � 3 c?t: list � form � preview app
   --------------------------------------------------- */
.main.gs-wide { max-width: none; padding-right: 14px; }

.gs-help {
  background: linear-gradient(135deg, #eff6ff 0%, #fdf2f8 100%);
  border: 1px solid #bfdbfe;
  border-radius: 14px;
  padding: 12px 16px;
  margin-bottom: 12px;
  font-size: 13.5px;
  color: #1e293b;
  line-height: 1.55;
}
.gs-help b { color: #1d4ed8; }
.gs-help .gs-steps {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px;
}
.gs-help .gs-step {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 700;
  color: #334155;
}
.gs-help .gs-step em {
  font-style: normal;
  color: #2563eb;
  margin-right: 4px;
}

.gs-toolbar {
  display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
  margin-bottom: 12px;
}
.gs-toolbar .grow { flex: 1; min-width: 160px; }
.gs-toolbar input[type="search"],
.gs-toolbar select {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 12px;
  background: #fff;
}

.gs-layout {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(360px, 1fr) minmax(280px, 340px);
  gap: 12px;
  align-items: start;
  min-height: 70vh;
}
/* Vòng ước nguyện · 2 cột · KHÔNG thanh kéo lồng (scroll 1 trang main) */
.gs-layout.mw-layout,
.gs-layout.mw-layout-flat {
  grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  align-items: start;
  min-height: auto;
}
.gs-layout.mw-layout-flat .gs-aside,
.gs-layout.mw-layout-flat .gs-main {
  min-height: 0;
  max-height: none;
  overflow: visible;
}
.gs-layout.mw-layout-flat .gs-list,
.mw-list-flat {
  max-height: none !important;
  overflow: visible !important;
}
.mw-svga-stage {
  position: relative;
}
.mw-svga-stage canvas {
  max-width: 100%;
  max-height: 220px;
  object-fit: contain;
}
.mw-editor-flat {
  padding: 14px 16px 24px;
  overflow: visible;
}
.mw-toolbar {
  flex-wrap: wrap;
  gap: 10px;
  align-items: flex-end;
}
.mw-toolbar input[type="number"] {
  width: 96px;
  font-weight: 700;
}
.mw-rars {
  margin: 10px 0 12px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.mw-editor-wrap .gs-media-grid-2 {
  max-width: 100%;
}
.gs-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 14px;
}
@media (max-width: 720px) {
  .gs-form-grid { grid-template-columns: 1fr; }
}
.gs-editor-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #64748b;
}
.gs-editor-title {
  margin: 2px 0 0;
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}
.gs-editor-empty {
  padding: 48px 20px;
  text-align: center;
}
@media (max-width: 1200px) {
  .gs-layout {
    grid-template-columns: minmax(200px, 240px) 1fr;
  }
  .gs-preview-col {
    grid-column: 1 / -1;
    max-width: 420px;
    margin: 0 auto;
    width: 100%;
  }
}
@media (max-width: 780px) {
  .gs-layout { grid-template-columns: 1fr; }
}

.gs-aside,
.gs-main,
.gs-preview-col {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
  overflow: hidden;
  min-height: 420px;
}
.gs-aside-title {
  padding: 12px 14px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #64748b;
  border-bottom: 1px solid var(--line);
  background: #f8fafc;
}
.gs-list {
  max-height: calc(100vh - 260px);
  overflow: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.gs-card {
  display: flex;
  gap: 10px;
  align-items: center;
  width: 100%;
  text-align: left;
  border: 1px solid transparent;
  background: #f8fafc;
  border-radius: 12px;
  padding: 8px 10px;
  cursor: pointer;
  transition: border-color .15s, background .15s, box-shadow .15s;
}
.gs-card:hover {
  border-color: #93c5fd;
  background: #eff6ff;
}
.gs-card.active {
  border-color: #2563eb;
  background: #dbeafe;
  box-shadow: 0 0 0 2px rgba(37,99,235,.15);
}
.gs-card.off { opacity: .55; }
.gs-card-icon {
  width: 48px; height: 48px; flex-shrink: 0;
  border-radius: 12px;
  display: grid; place-items: center;
  overflow: hidden;
  background-color: #e5e7eb;
  background-image:
    linear-gradient(45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(-45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #cbd5e1 75%),
    linear-gradient(-45deg, transparent 75%, #cbd5e1 75%);
  background-size: 12px 12px;
  background-position: 0 0, 0 6px, 6px -6px, -6px 0;
}
.gs-card-icon img {
  width: 100%; height: 100%; object-fit: contain;
}
.gs-emoji { font-size: 26px; line-height: 1; }
.gs-card-meta {
  min-width: 0; flex: 1;
  display: flex; flex-direction: column; gap: 2px;
}
.gs-card-meta b {
  font-size: 13px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gs-card-meta span {
  font-size: 11.5px; color: var(--muted);
}
.gs-tags {
  display: flex; flex-wrap: wrap; gap: 3px; margin-top: 2px;
}
.gs-tags .tag {
  font-style: normal;
  font-size: 9.5px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  letter-spacing: .02em;
}
.gs-tags .tag.svga { background: #ede9fe; color: #6d28d9; }
.gs-tags .tag.vid { background: #dbeafe; color: #1d4ed8; }
.gs-tags .tag.draw { background: #fce7f3; color: #be185d; }
.gs-tags .tag.on { background: #dcfce7; color: #15803d; }
.gs-tags .tag.off { background: #fee2e2; color: #b91c1c; }

.gs-editor { padding: 14px 16px 20px; }
.gs-form-head {
  display: flex; justify-content: space-between; align-items: center;
  gap: 8px; margin-bottom: 12px; flex-wrap: wrap;
}
.gs-form-head h3 { margin: 0; font-size: 18px; }
.gs-form-head .tiny {
  font-size: 11px; color: #64748b; background: #f1f5f9;
  padding: 3px 8px; border-radius: 6px;
}
.gs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  margin-bottom: 10px;
}
.gs-form label {
  display: flex; flex-direction: column; gap: 4px;
  font-size: 12px; font-weight: 700; color: #475569;
}
.gs-form label.gs-full { margin-bottom: 10px; }
.gs-form input,
.gs-form select,
.gs-form textarea {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  font-weight: 500;
  color: var(--ink);
  background: #fff;
}
.gs-form input:focus,
.gs-form select:focus,
.gs-form textarea:focus {
  outline: 2px solid #93c5fd;
  border-color: #2563eb;
}
.gs-checks {
  display: flex; flex-wrap: wrap; gap: 8px 14px;
  margin: 8px 0 14px;
  padding: 10px 12px;
  background: #f8fafc;
  border-radius: 12px;
  border: 1px solid #f1f5f9;
}
.gs-checks .chk {
  display: flex; flex-direction: row; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 650; color: #334155;
  cursor: pointer;
}
.gs-checks .chk input { width: 16px; height: 16px; accent-color: var(--primary); }

/* Media upload boxes */
.gs-media-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 12px 0;
}
.gs-media-grid-2 {
  grid-template-columns: 1fr 1fr;
  max-width: 560px;
}
.gs-media-grid-1 {
  grid-template-columns: 1fr;
  max-width: 280px;
}
.gs-form-simple .gs-form-head .tiny { color: #64748b; }
.gs-kind-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 0 0 14px;
}
.gs-kind-row-3 {
  grid-template-columns: 1fr 1fr 1fr;
}
.gs-kind-row-4 {
  grid-template-columns: 1fr 1fr 1fr 1fr;
}
@media (max-width: 1100px) {
  .gs-kind-row-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .gs-kind-row-3,
  .gs-kind-row-4 { grid-template-columns: 1fr; }
}
.gs-tag-draw {
  background: #ccfbf1;
  color: #0f766e;
}
.gs-tag-video {
  background: #dbeafe;
  color: #1d4ed8;
}
.gs-kind-opt {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  cursor: pointer;
  background: #fff;
  margin: 0;
}
.gs-kind-opt input { margin-top: 3px; accent-color: var(--primary); }
.gs-kind-opt span { display: flex; flex-direction: column; gap: 2px; }
.gs-kind-opt b { font-size: 13px; color: #0f172a; }
.gs-kind-opt small { font-size: 11px; color: #64748b; font-weight: 500; }
.gs-kind-opt.on {
  border-color: #6366f1;
  background: #eef2ff;
  box-shadow: 0 0 0 1px rgba(99, 102, 241, 0.25);
}
.gs-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 800;
  padding: 1px 6px;
  border-radius: 999px;
  vertical-align: middle;
  margin-left: 4px;
}
.gs-tag-static { background: #e2e8f0; color: #334155; }
.gs-tag-svga { background: #ede9fe; color: #6d28d9; }
.gs-tag-tab { background: #fef3c7; color: #b45309; }
#gs-filter,
#gs-tab-filter {
  max-width: 140px;
  font-size: 13px;
  border-radius: 10px;
  border: 1px solid var(--line);
  padding: 8px 10px;
  background: #fff;
}
@media (max-width: 900px) {
  .gs-media-grid,
  .gs-media-grid-2,
  .gs-media-grid-1 { grid-template-columns: 1fr; max-width: none; }
  .gs-kind-row { grid-template-columns: 1fr; }
}
.gs-media-box {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
  background: #fafbfc;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.gs-media-title {
  font-size: 12.5px;
  font-weight: 800;
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  flex-wrap: wrap;
}
.gs-media-title .ok-txt {
  font-size: 10px;
  font-weight: 800;
  color: #15803d;
  background: #dcfce7;
  padding: 2px 7px;
  border-radius: 999px;
}
.gs-media-prev {
  height: 140px;
  border-radius: 12px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  overflow: hidden;
  position: relative;
  cursor: pointer;
}
.gs-media-prev.checker {
  background-color: #e5e7eb;
  background-image:
    linear-gradient(45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(-45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #cbd5e1 75%),
    linear-gradient(-45deg, transparent 75%, #cbd5e1 75%);
  background-size: 14px 14px;
  background-position: 0 0, 0 7px, 7px -7px, -7px 0;
}
/* Icon slot kiểu CMS gốc: khung dashed sáng, xem file nguyên */
.gs-media-prev.gs-icon-slot {
  background: #fafafa;
  border: 1.5px dashed #cbd5e1;
  min-height: 160px;
  height: 160px;
}
.gs-media-prev.gs-icon-slot img {
  max-width: 88%;
  max-height: 88%;
  object-fit: contain;
}
/* SVGA slot: cover = thumb + badge phát */
.gs-media-prev.gs-svga-slot {
  position: relative;
}
.gs-media-prev.gs-svga-slot .gs-svga-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
  opacity: 0.55;
  pointer-events: none;
}
.gs-media-prev.gs-svga-slot .badge {
  position: relative;
  z-index: 1;
}
.gs-fx-thumb-intro {
  display: grid;
  place-items: center;
  height: 100%;
  gap: 10px;
}
.gs-fx-thumb-intro img {
  max-width: 42%;
  max-height: 42%;
  object-fit: contain;
  filter: drop-shadow(0 8px 24px rgba(236, 72, 153, 0.35));
}
.gs-fx-thumb-label {
  font-size: 12px;
  font-weight: 800;
  color: #e2e8f0;
  background: rgba(0,0,0,.45);
  padding: 6px 12px;
  border-radius: 999px;
}
.gs-media-prev.dark {
  background: radial-gradient(ellipse at center, #1e1b4b 0%, #0f172a 70%);
  color: #e2e8f0;
}
.gs-media-prev img,
.gs-media-prev video {
  max-width: 92%;
  max-height: 92%;
  object-fit: contain;
}
.gs-media-prev video { width: 100%; height: 100%; object-fit: contain; }
.gs-media-prev .badge.hot {
  background: linear-gradient(135deg, #7c3aed, #db2777);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  padding: 6px 12px;
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(124,58,237,.4);
}
.gs-media-prev .muted { color: #94a3b8; font-size: 12px; text-align: center; padding: 8px; }
.gs-media-box input[type="file"] {
  font-size: 11.5px;
  width: 100%;
}
.gs-media-box .gs-media-btns {
  display: flex; gap: 6px; flex-wrap: wrap;
}
.gs-media-box .gs-media-btns .btn {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  padding: 6px 8px;
}

.gs-actions {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  position: sticky;
  bottom: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.92), #fff 30%);
  z-index: 2;
}
.gs-actions .btn { font-size: 13px; }

/* Preview column � phone mock */
.gs-preview-col { display: flex; flex-direction: column; }
.gs-stage {
  padding: 12px 12px 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  background: linear-gradient(180deg, #f1f5f9 0%, #e2e8f0 100%);
  min-height: 480px;
}
.gs-stage-empty {
  color: var(--muted);
  text-align: center;
  padding: 48px 16px;
  font-size: 14px;
}
.gs-stage-label {
  font-size: 11.5px;
  font-weight: 800;
  color: #475569;
  text-align: center;
  letter-spacing: .02em;
  text-transform: uppercase;
  width: 100%;
}
.gs-phone {
  width: min(280px, 100%);
  background: #0f172a;
  border-radius: 28px;
  padding: 10px;
  box-shadow: 0 16px 40px rgba(15,23,42,.35), inset 0 0 0 2px #334155;
}
.gs-phone.tall { width: min(300px, 100%); }
.gs-phone-bar {
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 800;
  text-align: center;
  padding: 6px 8px 10px;
  letter-spacing: .04em;
}
.gs-phone-body {
  border-radius: 18px;
  overflow: hidden;
  min-height: 320px;
  position: relative;
}
.gs-phone-body.checker-lg {
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background-color: #e5e7eb;
  background-image:
    linear-gradient(45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(-45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #cbd5e1 75%),
    linear-gradient(-45deg, transparent 75%, #cbd5e1 75%);
  background-size: 18px 18px;
  background-position: 0 0, 0 9px, 9px -9px, -9px 0;
  padding: 20px 12px;
}
.gs-phone-body.dark-panel {
  background: #1e1b4b;
  padding: 10px;
  min-height: 360px;
}
.gs-phone-body.fx-stage {
  background: linear-gradient(180deg, #1a0a2e 0%, #0f172a 50%, #1e293b 100%);
  min-height: 420px;
  aspect-ratio: 9 / 16;
  max-height: 520px;
}
.gs-big-icon {
  max-width: min(220px, 78%);
  max-height: min(260px, 58%);
  width: auto;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 0 18px rgba(236, 72, 153, 0.25));
  image-rendering: auto;
}
.gs-big-emoji { font-size: 88px; line-height: 1; }
.gs-icon-cap {
  font-size: 13px;
  font-weight: 800;
  color: #0f172a;
  background: rgba(255,255,255,.85);
  padding: 6px 14px;
  border-radius: 999px;
}
/* Icon glow trên nền tối (đúng app) — tránh caro sáng làm FX “ma” */
.iphone-icon-dark {
  background:
    radial-gradient(ellipse at 50% 42%, #1e1b4b 0%, #0b1020 62%, #05070f 100%);
}
.iphone-icon-dark .gs-icon-cap {
  color: #f8fafc;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(148, 163, 184, 0.25);
}
.iphone-icon-view.checker-bg .gs-icon-cap {
  color: #0f172a;
  background: rgba(255,255,255,.85);
  border: 0;
}

/* In-app gift panel mock */
.gs-panel-tabs {
  display: flex; gap: 4px; margin-bottom: 10px;
}
.gs-panel-tabs span {
  flex: 1;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: #94a3b8;
  padding: 6px 2px;
  border-radius: 8px;
}
.gs-panel-tabs span.on {
  color: #fff;
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
}
.gs-panel-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.gs-panel-cell {
  background: rgba(255,255,255,.06);
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 8px 4px;
  text-align: center;
}
.gs-panel-cell.sel {
  border-color: #f472b6;
  background: rgba(244,114,182,.15);
  box-shadow: 0 0 0 1px rgba(244,114,182,.4);
}
.gs-panel-icon {
  width: 52px; height: 52px;
  margin: 0 auto 4px;
  border-radius: 10px;
  display: grid; place-items: center;
  overflow: hidden;
}
.gs-panel-icon.checker {
  background-color: #e5e7eb;
  background-image:
    linear-gradient(45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(-45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #cbd5e1 75%),
    linear-gradient(-45deg, transparent 75%, #cbd5e1 75%);
  background-size: 10px 10px;
  background-position: 0 0, 0 5px, 5px -5px, -5px 0;
}
.gs-panel-icon img {
  max-width: 90%; max-height: 90%; object-fit: contain;
}
.gs-panel-icon span { font-size: 28px; }
.gs-panel-name {
  font-size: 10px; color: #e2e8f0; font-weight: 700;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gs-panel-price {
  font-size: 10px; color: #93c5fd; font-weight: 800;
}
.gs-panel-send {
  width: 100%;
  border: 0;
  border-radius: 999px;
  padding: 10px;
  font-weight: 800;
  font-size: 14px;
  color: #fff;
  background: linear-gradient(135deg, #f472b6, #a855f7);
  cursor: default;
}

/* FX layer inside phone */
.gs-fx-room {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(255,255,255,.25);
  font-size: 13px;
  font-weight: 700;
  pointer-events: none;
  z-index: 0;
}
.gs-fx-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.gs-fx-layer canvas,
.gs-fx-layer video {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
  max-width: 100%;
  max-height: 100%;
}
.gs-fx-status {
  color: #e2e8f0;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  padding: 16px;
  z-index: 3;
}
.gs-fx-status.err { color: #fecaca; }
.gs-fx-banner {
  position: absolute;
  left: 8px; right: 8px; bottom: 12px;
  z-index: 4;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: 11px;
  padding: 8px 10px;
  border-radius: 10px;
  text-align: center;
}
.gs-fx-emoji-play {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  animation: gs-pop 0.6s ease both;
}
.gs-fx-emoji-play img {
  width: 120px; height: 120px; object-fit: contain;
  filter: drop-shadow(0 0 24px rgba(244,114,182,.6));
}
.gs-fx-emoji-play span { font-size: 96px; line-height: 1; }
.gs-fx-combo {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: #422006;
  font-weight: 900;
  font-size: 14px;
  padding: 4px 14px;
  border-radius: 999px;
  letter-spacing: .06em;
  animation: gs-combo 0.8s ease infinite alternate;
}
@keyframes gs-pop {
  0% { transform: scale(0.2); opacity: 0; }
  60% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(1); }
}
@keyframes gs-combo {
  from { transform: scale(1); }
  to { transform: scale(1.08); }
}
.gs-fx-btns {
  display: flex; flex-wrap: wrap; gap: 6px; justify-content: center;
  width: 100%;
  margin-top: 4px;
}
.gs-fx-btns .btn { font-size: 12px; padding: 7px 10px; }

.ok-txt { color: #15803d; font-weight: 800; }

/* ---------------------------------------------------
   iPhone frame � xem SVGA / MP4 / icon full m�n
   --------------------------------------------------- */
.iphone-modal-wrap {
  display: flex;
  justify-content: center;
  padding: 8px 0 4px;
}
.iphone-modal-meta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  text-align: center;
}
.iphone-modal-meta .badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 999px;
  background: #dbeafe;
  color: #1d4ed8;
}
.iphone-modal-meta .badge.hot {
  background: linear-gradient(135deg, #7c3aed, #db2777);
  color: #fff;
}
.modal-card.modal-iphone {
  width: min(440px, 100%);
  background: #0b1220;
  color: #e2e8f0;
}
.modal-card.modal-iphone .modal-head {
  background: #0b1220;
  border-bottom-color: #1e293b;
  color: #fff;
}
.modal-card.modal-iphone .modal-head h2 { color: #fff; }
.modal-card.modal-iphone .modal-foot {
  background: #0b1220;
  border-top-color: #1e293b;
}
.modal-card.modal-iphone .muted { color: #94a3b8; }

.iphone {
  position: relative;
  width: 280px;
  margin: 0 auto;
  user-select: none;
}
.iphone-sm { width: 240px; }
.iphone-md { width: 280px; }
.iphone-lg { width: min(320px, 86vw); }

.iphone-bezel {
  background: linear-gradient(160deg, #3f3f46 0%, #18181b 40%, #09090b 100%);
  border-radius: 44px;
  padding: 11px;
  box-shadow:
    0 0 0 2px #27272a,
    0 0 0 4px #0a0a0a,
    0 22px 50px rgba(0,0,0,.45),
    inset 0 1px 0 rgba(255,255,255,.12);
}

.iphone-screen {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 19.5;
  max-height: min(72vh, 640px);
  border-radius: 34px;
  overflow: hidden;
  background: #000;
  display: flex;
  flex-direction: column;
}
.iphone-screen.theme-light { background: #f1f5f9; }
.iphone-screen.theme-dark { background: #0f172a; }
.iphone-screen.theme-fx {
  background: linear-gradient(180deg, #1a0a2e 0%, #0f172a 45%, #1e293b 100%);
}

/* side buttons */
.iphone-btn {
  position: absolute;
  background: #27272a;
  border-radius: 2px;
  z-index: 2;
}
.iphone-btn-silent {
  left: -3px; top: 92px;
  width: 3px; height: 22px;
  border-radius: 2px 0 0 2px;
}
.iphone-btn-vol-up {
  left: -3px; top: 130px;
  width: 3px; height: 36px;
  border-radius: 2px 0 0 2px;
}
.iphone-btn-vol-down {
  left: -3px; top: 176px;
  width: 3px; height: 36px;
  border-radius: 2px 0 0 2px;
}
.iphone-btn-power {
  right: -3px; top: 148px;
  width: 3px; height: 56px;
  border-radius: 0 2px 2px 0;
}

/* status bar + Dynamic Island */
.iphone-status {
  position: relative;
  z-index: 5;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 10px 16px 4px;
  min-height: 36px;
  pointer-events: none;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.iphone-screen.theme-light .iphone-status { color: #0f172a; }
.iphone-time { justify-self: start; padding-left: 4px; letter-spacing: .02em; }
.iphone-island {
  justify-self: center;
  width: 86px;
  height: 24px;
  background: #000;
  border-radius: 20px;
  box-shadow: inset 0 0 0 1px #1c1c1e;
}
.iphone-screen.theme-light .iphone-island {
  background: #0a0a0a;
}
.iphone-sys {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 5px;
  padding-right: 2px;
}
.iphone-sig {
  display: inline-block;
  width: 14px; height: 10px;
  background:
    linear-gradient(to top, currentColor 0 100%) 0 100%/2px 40% no-repeat,
    linear-gradient(to top, currentColor 0 100%) 4px 100%/2px 55% no-repeat,
    linear-gradient(to top, currentColor 0 100%) 8px 100%/2px 75% no-repeat,
    linear-gradient(to top, currentColor 0 100%) 12px 100%/2px 100% no-repeat;
  opacity: .95;
}
.iphone-wifi {
  display: inline-block;
  width: 13px; height: 10px;
  border: 2px solid currentColor;
  border-top: 0; border-left: 0; border-right: 0;
  border-radius: 0 0 50% 50%;
  position: relative;
  opacity: .9;
  transform: translateY(-1px);
}
.iphone-wifi::before {
  content: "";
  position: absolute;
  left: 2px; right: 2px; bottom: 2px;
  height: 4px;
  border: 1.5px solid currentColor;
  border-top: 0; border-left: 0; border-right: 0;
  border-radius: 0 0 50% 50%;
}
.iphone-bat {
  display: inline-flex;
  align-items: center;
  width: 20px; height: 10px;
  border: 1.5px solid currentColor;
  border-radius: 3px;
  padding: 1px;
  position: relative;
  opacity: .95;
}
.iphone-bat::after {
  content: "";
  position: absolute;
  right: -3px; top: 2px;
  width: 2px; height: 4px;
  background: currentColor;
  border-radius: 0 1px 1px 0;
  opacity: .7;
}
.iphone-bat em {
  display: block;
  width: 72%;
  height: 100%;
  background: #4ade80;
  border-radius: 1px;
}

.iphone-appbar {
  position: relative;
  z-index: 4;
  text-align: center;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .03em;
  color: rgba(255,255,255,.88);
  padding: 2px 10px 6px;
  text-shadow: 0 1px 2px rgba(0,0,0,.4);
}
.iphone-screen.theme-light .iphone-appbar {
  color: #334155;
  text-shadow: none;
}

.iphone-stage {
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  display: grid;
  place-items: center;
}
.iphone-stage > * {
  width: 100%;
  height: 100%;
}

/* ── Săn số thần tài · admin gọn 2 quà ── */
.tt-easy { max-width: 1200px; }
.tt-easy-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 16px;
}
.tt-easy-title {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 900;
  color: #ffe082;
}
.tt-easy-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.tt-easy-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
}
.tt-easy-main {
  flex: 1 1 340px;
  min-width: 280px;
}
.tt-section {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 14px;
}
.tt-h3 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 800;
}
.tt-gifts-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 640px) {
  .tt-gifts-row { grid-template-columns: 1fr; }
}
.tt-gift-card {
  background: linear-gradient(160deg, #1a0c28, #0c0814);
  border: 1px solid rgba(224, 64, 251, 0.28);
  border-radius: 14px;
  padding: 14px 12px;
  text-align: center;
  position: relative;
}
.tt-gift-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.tt-gift-no {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.45);
  margin-bottom: 0;
}
.tt-banner-box-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.tt-banner-del {
  flex-shrink: 0;
  padding: 2px 8px !important;
  font-size: 11px !important;
}
.tt-dia-chest-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.tt-ed-gift-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.tt-ed-gift-head .tt-ed-del {
  margin-left: auto;
}
.tt-ed-img-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}
.tt-ed-img-head .lbl { margin: 0; }
.tt-gift-icon {
  width: 88px;
  height: 88px;
  margin: 0 auto 8px;
  border-radius: 14px;
  background: #111;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.tt-gift-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.tt-gift-ph { font-size: 40px; line-height: 1; }
.tt-gift-price {
  font-weight: 900;
  color: #ffe082;
  font-size: 15px;
}
.tt-gift-name {
  margin-top: 2px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  font-weight: 700;
}
.tt-banner-row {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr;
  gap: 10px;
}
@media (max-width: 800px) {
  .tt-banner-row { grid-template-columns: 1fr; }
}
.tt-banner-box {
  background: #0a0a0c;
  border-radius: 10px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.tt-banner-img {
  display: block;
  width: 100%;
  max-height: 100px;
  object-fit: cover;
  border-radius: 8px;
  margin-top: 6px;
  background: #111;
}
.tt-banner-img.tall {
  max-height: 160px;
  object-fit: contain;
}
.tt-banner-empty {
  margin-top: 6px;
  padding: 18px 10px;
  text-align: center;
  color: rgba(255, 255, 255, 0.35);
  font-size: 12px;
  border-radius: 8px;
  background: #111;
}
.tt-banner-empty.tall { min-height: 120px; display: grid; place-items: center; }
.tt-dia-chest {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 8px;
  min-height: 56px;
}
.tt-dia-chest img {
  max-width: 56px;
  max-height: 56px;
  object-fit: contain;
  background: #111;
  border-radius: 8px;
}
.tt-tips ol {
  margin: 8px 0 0;
  padding-left: 18px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 13px;
  line-height: 1.5;
}
.tt-pool-live { color: #ffe082; }

/* Form sửa nhanh */
.tt-ed { display: flex; flex-direction: column; gap: 14px; }
.tt-ed-top {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}
.tt-ed-top .chk.big { font-weight: 800; font-size: 14px; }
.tt-ed-sec {
  margin: 8px 0 0;
  font-size: 14px;
  font-weight: 900;
  color: #e9d5ff;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 12px;
}
.tt-ed-gifts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 640px) {
  .tt-ed-gifts { grid-template-columns: 1fr; }
}
.tt-ed-gift {
  background: rgba(90, 30, 140, 0.12);
  border: 1px solid rgba(224, 64, 251, 0.25);
  border-radius: 12px;
  padding: 12px;
}
.tt-ed-gift-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 10px;
}
.tt-ed-gift-body {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.tt-ed-thumb {
  width: 72px;
  height: 72px;
  border-radius: 12px;
  background: #111;
  display: grid;
  place-items: center;
  overflow: hidden;
  flex-shrink: 0;
}
.tt-ed-thumb img { width: 100%; height: 100%; object-fit: contain; }
.tt-ed-gift-fields { flex: 1; min-width: 0; }
.tt-ed-banners {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr 0.7fr 0.7fr;
  gap: 10px;
}
@media (max-width: 800px) {
  .tt-ed-banners { grid-template-columns: 1fr 1fr; }
}
.tt-ed-img {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 10px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.tt-ed-img-prev {
  height: 72px;
  margin: 6px 0;
  border-radius: 8px;
  background: #111;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.tt-ed-img.tall .tt-ed-img-prev { height: 110px; }
.tt-ed-img-prev img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.tt-admin-layout {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
}
.tt-phone-wrap {
  flex: 0 0 auto;
  margin: 0 auto;
}
.tt-phone-screen {
  height: 100%;
  overflow: auto;
  padding: 8px 10px 14px;
  box-sizing: border-box;
  background: linear-gradient(180deg, #4a1a6b 0%, #1a0c28 45%, #0a0608 100%);
  color: #fff;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-overflow-scrolling: touch;
}
.tt-marquee {
  height: 28px;
  border-radius: 99px;
  background: rgba(255, 213, 79, 0.12);
  border: 1px solid rgba(255, 213, 79, 0.35);
  overflow: hidden;
  white-space: nowrap;
  display: flex;
  align-items: center;
  margin-bottom: 8px;
}
.tt-marquee span {
  display: inline-block;
  padding-left: 100%;
  animation: tt-scroll 14s linear infinite;
  color: #ffe082;
  font-weight: 800;
  font-size: 11px;
}
@keyframes tt-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}
.tt-sub {
  text-align: center;
  color: rgba(255, 255, 255, 0.65);
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 10px;
}
.tt-pot {
  border-radius: 18px;
  padding: 14px 12px 12px;
  /* Đen mờ · thấy banner/nền sau (khớp app) */
  background: rgba(0, 0, 0, 0.42);
  border: 1.1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
  text-align: center;
  margin-bottom: 12px;
}
.tt-pot-label {
  color: rgba(255, 255, 255, 0.5);
  font-weight: 800;
  letter-spacing: 2.5px;
  font-size: 10px;
  margin-bottom: 8px;
}
.tt-pot-glow {
  position: relative;
  height: 96px;
  display: grid;
  place-items: center;
  margin-bottom: 6px;
}
.tt-pot-glow::before {
  content: "";
  position: absolute;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 213, 79, 0.18), transparent 70%);
}
.tt-chest {
  position: relative;
  width: 88px;
  height: 88px;
  object-fit: contain;
  z-index: 1;
}
.tt-chest-emoji {
  font-size: 64px;
  line-height: 1;
  z-index: 1;
}
.tt-pool-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 4px 0 6px;
}
.tt-dia {
  width: 28px;
  height: 28px;
  object-fit: contain;
}
.tt-dia-emoji {
  font-size: 22px;
}
.tt-pool-num {
  color: #ffe082;
  font-weight: 900;
  font-size: 34px;
  line-height: 1;
  letter-spacing: 0.5px;
  text-shadow: 0 0 14px rgba(180, 77, 232, 0.65);
  font-variant-numeric: tabular-nums;
}
.tt-pool-hint {
  color: rgba(255, 255, 255, 0.45);
  font-size: 11px;
  font-weight: 600;
  margin-bottom: 10px;
}
.tt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}
.tt-chip {
  padding: 4px 10px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.72);
  font-size: 10px;
  font-weight: 700;
}
.tt-winners-h {
  color: rgba(255, 255, 255, 0.9);
  font-weight: 900;
  font-size: 12.5px;
  margin: 4px 0 8px;
}
.tt-winners-empty {
  border-radius: 12px;
  padding: 18px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.4);
  font-size: 11px;
  text-align: center;
  line-height: 1.4;
}

.iphone-home {
  position: absolute;
  left: 50%;
  bottom: 7px;
  transform: translateX(-50%);
  width: 104px;
  height: 4px;
  border-radius: 4px;
  background: rgba(255,255,255,.55);
  z-index: 6;
  pointer-events: none;
}
.iphone-screen.theme-light .iphone-home {
  background: rgba(15,23,42,.35);
}

/* media fill iPhone screen */
.iphone-media,
.iphone-stage video,
.iphone-stage img.iphone-media {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
  background: #000;
  display: block;
}
/* Icon PNG trong suốt: không phủ đen full màn — nền do wrap (tối / caro) quyết định */
.iphone-media-icon,
.iphone-img-wrap > img.iphone-media {
  background: transparent !important;
  max-width: 82% !important;
  max-height: 82% !important;
  width: auto !important;
  height: auto !important;
  margin: auto;
  align-self: center;
}
.iphone-img-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
}
.iphone-img-wrap,
.iphone-icon-view {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 16px 12px 28px;
}
.checker-bg {
  background-color: #e5e7eb;
  background-image:
    linear-gradient(45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(-45deg, #cbd5e1 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #cbd5e1 75%),
    linear-gradient(-45deg, transparent 75%, #cbd5e1 75%);
  background-size: 16px 16px;
  background-position: 0 0, 0 8px, 8px -8px, -8px 0;
}

.iphone-panel-view {
  width: 100%;
  height: 100%;
  padding: 8px 10px 28px;
  background: linear-gradient(180deg, #1e1b4b 0%, #0f172a 100%);
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}
.iphone-panel-hint {
  margin: 8px 0 0;
  text-align: center;
  font-size: 10px;
  color: #94a3b8;
}

/* FX layer inside iPhone stage */
.iphone-stage .gs-fx-room {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(255,255,255,.22);
  font-size: 12px;
  font-weight: 700;
  pointer-events: none;
  z-index: 0;
}
.iphone-stage .gs-fx-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.iphone-stage .gs-fx-layer canvas,
.iphone-stage .gs-fx-layer video {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
}
.iphone-stage .gs-fx-banner {
  position: absolute;
  left: 8px; right: 8px; bottom: 22px;
  z-index: 4;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: 11px;
  padding: 8px 10px;
  border-radius: 10px;
  text-align: center;
}

/* Gift studio stage uses iPhone */
.gs-stage .iphone { margin-top: 4px; }
.gs-stage .iphone-md { width: min(270px, 100%); }
.gs-preview-col {
  min-height: 560px;
}
.gs-stage {
  min-height: 560px;
  padding-bottom: 20px;
}

/* legacy phone-frame still OK for other places */
.phone-frame {
  /* keep older styles; prefer .iphone */
}

.iphone-fx-root {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 100%;
  overflow: hidden;
  background: transparent;
}
.iphone-stage {
  position: relative;
}
.iphone-stage > .iphone-fx-root,
.iphone-stage > .iphone-panel-view,
.iphone-stage > .iphone-icon-view,
.iphone-stage > .iphone-img-wrap,
.iphone-stage > .svga-wrap,
.iphone-stage > video,
.iphone-stage > .iphone-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.iphone-fx-root .gs-fx-room {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(255,255,255,.22);
  font-size: 12px;
  font-weight: 700;
  pointer-events: none;
  z-index: 0;
}
.iphone-fx-root .gs-fx-layer {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.iphone-fx-root .gs-fx-layer canvas,
.iphone-fx-root .gs-fx-layer video {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
  background: transparent;
}
.iphone-fx-root .gs-fx-banner {
  position: absolute;
  left: 8px; right: 8px; bottom: 22px;
  z-index: 4;
  background: rgba(0,0,0,.55);
  backdrop-filter: blur(6px);
  color: #fff;
  font-size: 11px;
  padding: 8px 10px;
  border-radius: 10px;
  text-align: center;
}

/* Gift simple */
.gs-help-simple { font-size: 14px; }
.gs-grid-simple {
  grid-template-columns: 1.4fr 80px 120px !important;
}
@media (max-width: 700px) {
  .gs-grid-simple { grid-template-columns: 1fr !important; }
}
.gs-aside {
  min-height: 520px;
}
.gs-list {
  max-height: calc(100vh - 220px);
}
.gs-card {
  min-height: 58px;
}
.gs-card-meta b { font-size: 14px; }
.gs-card-meta span { font-size: 12.5px; }

/* -- Gacha studio -- */
.gc-layout {
  display: grid;
  grid-template-columns: minmax(320px, 1fr) minmax(280px, 380px);
  gap: 16px;
  margin-top: 12px;
  align-items: start;
}
@media (max-width: 960px) {
  .gc-layout { grid-template-columns: 1fr; }
}
.gc-machine {
  background: linear-gradient(145deg, #2a1e0a, #1a1208 50%, #120e06);
  border: 1.5px solid #ffd54acc;
  border-radius: 20px;
  padding: 14px;
  box-shadow: 0 10px 28px rgba(255, 184, 55, 0.2);
}
.gc-machine-title {
  color: #ffe08a;
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 12px;
  text-align: center;
}
.gc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.gc-grid.gc-grid-18 {
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
}
.gc-grid.gc-grid-18 .gc-cell {
  min-height: 96px;
  padding: 6px 4px;
}
.gc-num {
  position: absolute;
  top: 4px;
  left: 6px;
  font-size: 10px;
  font-weight: 900;
  color: #fff;
  background: #0f172acc;
  border-radius: 6px;
  padding: 1px 5px;
  line-height: 1.2;
  z-index: 2;
}
.gc-kind {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 8px;
  font-weight: 900;
  color: #fff;
  border-radius: 4px;
  padding: 1px 4px;
  line-height: 1.2;
  z-index: 2;
}
.gc-kind.static {
  background: #64748b;
}
.gc-kind.screen {
  background: #2563eb;
}
.gc-kind.svga {
  background: #c026d3;
}
.gs-kind-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 12px;
}
.gs-kind-opt {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  padding: 6px 10px;
  border-radius: 10px;
  border: 1.5px solid #e2e8f0;
  background: #f8fafc;
  cursor: pointer;
}
.gs-kind-opt:has(input:checked) {
  border-color: #c084fc;
  background: #faf5ff;
  color: #6b21a8;
}
.gc-cell {
  position: relative;
  min-height: 110px;
  border-radius: 16px;
  border: 1.5px solid #fff6;
  background: linear-gradient(160deg, #fff, #fff0f6 70%, #ffe8f0);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  padding: 8px 6px;
  transition: transform .15s, box-shadow .15s;
  font: inherit;
  color: #3a2040;
}
.gc-cell:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(255, 90, 154, 0.25);
  border-color: #ff6ba8;
}
.gc-cell.on {
  border-color: #a78bfa;
  box-shadow: 0 0 0 2px #a78bfa88, 0 8px 18px rgba(167, 139, 250, 0.35);
  background: linear-gradient(160deg, #f5f0ff, #fff0f6 70%, #ffe8f0);
}
.gc-cell b {
  font-size: 12px;
  font-weight: 800;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.gc-cell small {
  font-size: 11px;
  color: #8a4060;
  font-weight: 700;
}
.gc-thumb {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
}
.gc-thumb img {
  max-width: 44px;
  max-height: 44px;
  object-fit: contain;
}
.gc-emoji { font-size: 28px; line-height: 1; }
.gc-rare {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 9px;
  font-weight: 900;
  background: #ff8a3d;
  color: #fff;
  padding: 1px 5px;
  border-radius: 99px;
}
.gc-super {
  cursor: default;
  background: radial-gradient(circle at 40% 30%, #fff, #ffe0f0, #ff9ec8aa);
  border: 2px solid #e040fb88;
}
.gc-super:hover { transform: none; box-shadow: none; }
.gc-super-ring {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 22px;
  background: #fff8;
  border: 2px solid #e040fb55;
}
.gc-side {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  min-height: 360px;
}
.gc-tier-tabs { display: flex; flex-wrap: wrap; gap: 6px; }

/* -- Give to user (admin t?ng qu� / balo) -- */
.gs-card-row {
  display: flex;
  align-items: stretch;
  gap: 6px;
  margin-bottom: 6px;
}
.gs-card-row .gs-card {
  flex: 1;
  margin: 0;
}
.gs-give-btn {
  align-self: center;
  white-space: nowrap;
  min-width: 52px;
  font-weight: 800;
}
.give-box { display: flex; flex-direction: column; gap: 10px; }
.give-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 12px;
}
.give-item-thumb {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 10px;
  background: #fff;
}
.give-item-emoji { font-size: 32px; line-height: 1; }
.give-user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1.5px solid #86efac;
  background: #f0fdf4;
}
.give-avt {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,.12);
}
.give-avt-ph {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #fda4af, #c084fc);
  color: #fff;
  font-weight: 900;
  font-size: 20px;
}

.give-field-label {
  display: block;
  font-weight: 800;
  font-size: 13px;
  color: #0f172a;
  margin-bottom: 2px;
}
.give-field input[type=number] {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1.5px solid #cbd5e1;
}

.give-avt-wrap {
  position: relative;
  width: 52px;
  height: 52px;
  flex-shrink: 0;
}
.give-avt-wrap .give-avt {
  position: absolute;
  inset: 0;
}

/* ── Avt user đồng bộ (list / tìm ID / ban / tặng) ── */
.user-avt-wrap {
  position: relative;
  flex-shrink: 0;
  border-radius: 50%;
  overflow: hidden;
}
.user-avt {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  border: 2px solid #fff;
  box-shadow: 0 1px 6px rgba(15, 23, 42, 0.12);
  background: #f1f5f9;
}
.user-avt-ph {
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, #fda4af, #c084fc);
  color: #fff;
  font-weight: 900;
  flex-shrink: 0;
  border: 2px solid #fff;
  box-shadow: 0 1px 6px rgba(15, 23, 42, 0.1);
  box-sizing: border-box;
}
.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.user-chip-meta {
  min-width: 0;
  flex: 1;
}
.user-chip-name {
  display: block;
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.user-chip-sub {
  margin-top: 2px;
  color: #64748b;
}
.user-detail-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding: 12px 14px;
  border-radius: 14px;
  background: linear-gradient(135deg, #fdf2f8, #f5f3ff);
  border: 1px solid #f5d0fe;
}
/* give modal · tái dùng user-avt */
.give-user {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* -- Avatar / AVT studio preview -- */
.av-list-thumb {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  background: linear-gradient(135deg, #2a1050, #1a0a30);
  border: 2px solid #e9d5ff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 16px;
}
.av-list-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.av-stage {
  padding: 16px 12px 20px;
  background: linear-gradient(180deg, #12081f 0%, #0a0618 100%);
  min-height: 420px;
}
.avt-prev-stage {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.avt-prev-phone {
  width: min(260px, 100%);
  border-radius: 28px;
  background: #0f0a1c;
  border: 3px solid #2a2040;
  box-shadow: 0 20px 40px rgba(0,0,0,.35), inset 0 0 0 1px rgba(255,255,255,.06);
  overflow: hidden;
}
.avt-prev-notch {
  width: 88px;
  height: 10px;
  margin: 10px auto 0;
  border-radius: 99px;
  background: #1a1228;
}
.avt-prev-body {
  padding: 28px 18px 24px;
  text-align: center;
  position: relative;
}
.avt-prev-halo {
  position: absolute;
  left: 50%;
  top: 36%;
  transform: translate(-50%, -50%);
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,77,154,.35), transparent 70%);
  pointer-events: none;
}
.avt-prev-ring {
  width: 132px;
  height: 132px;
  margin: 0 auto;
  border-radius: 50%;
  border: 3px solid rgba(255,255,255,.55);
  overflow: hidden;
  position: relative;
  background: #1a0a30;
  box-shadow: 0 0 0 4px rgba(255,77,154,.25), 0 12px 28px rgba(0,0,0,.35);
}
.avt-prev-ring.has-frame {
  border-color: transparent;
  box-shadow: none;
  overflow: visible;
  background: transparent;
}
.avt-prev-img,
.avt-prev-ph {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 42px;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, #ff6ba8, #9b7ede);
}
.avt-prev-frame {
  position: absolute;
  inset: -10%;
  width: 120%;
  height: 120%;
  left: -10%;
  top: -10%;
  object-fit: contain;
  pointer-events: none;
  z-index: 2;
}
.avt-prev-name {
  margin-top: 16px;
  font-size: 18px;
  font-weight: 900;
  color: #fff;
  letter-spacing: .02em;
}
.avt-prev-meta {
  margin-top: 8px;
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
}
.avt-prev-sizes {
  margin-top: 16px;
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: flex-end;
}
.avt-mini {
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,.45);
  background: #2a1050;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
  font-size: 11px;
  box-shadow: 0 4px 12px rgba(0,0,0,.3);
}
.avt-mini img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.avt-prev-boards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  width: 100%;
  max-width: 280px;
}
.avt-board {
  aspect-ratio: 1;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255,255,255,.12);
}
.avt-board-ring {
  width: 70%;
  height: 70%;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,.5);
  background: #1a0a30;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 800;
}
.avt-board-ring img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gs-editor-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: #faf5ff;
}
.gs-editor-acts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.gs-editor-foot {
  padding: 12px 16px 16px;
  border-top: 1px solid var(--line);
  background: #f8fafc;
  display: flex;
  justify-content: flex-end;
}
