:root {
  --brand: #5c00ff;
  --brand-light: #8b5cf6;
  --brand-glow: rgba(92, 0, 255, 0.45);
  --brand-dim: rgba(92, 0, 255, 0.12);
  --bg: #09090d;
  --surface: rgba(22, 22, 30, 0.85);
  --surface-solid: #16161e;
  --surface-2: #1e1e28;
  --surface-hover: #262632;
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(92, 0, 255, 0.4);
  --text: #f4f4f8;
  --muted: #8b8ba0;
  --success: #43b581;
  --success-dim: rgba(67, 181, 129, 0.15);
  --warning: #ff6600;
  --warning-dim: rgba(255, 102, 0, 0.12);
  --error: #ed4245;
  --error-dim: rgba(237, 66, 69, 0.12);
  --discord: #5865f2;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --font-body: 'Outfit', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Space Grotesk', var(--font-body);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: -0.008em;
  background: #050508;
  color: var(--text);
  min-height: 100vh;
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3,
.brand-name,
.page-title,
.landing-title,
.landing-card-name,
.landing-profile-name,
.panel-title,
.flow-header h3,
.auth-inner h3,
.gift-confirm-header h3,
.session-panel-title,
.shop-card-title,
.shop-empty-title,
.hero-title,
.overview-hero-title,
.overview-hero-eyebrow,
.settings-card-title,
.header-user-name,
.settings-epic-badge-value,
.settings-outcome-title {
  font-family: var(--font-display);
  letter-spacing: -0.03em;
  font-weight: 700;
}

.stat-value,
.session-countdown-value,
.shop-card-price .vbuck-amt {
  font-family: var(--font-display);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.stat-label,
.panel-sub,
.shop-sort-label,
.landing-stack-label,
.landing-credits-title,
.session-countdown-label,
.flow-tag,
.beta-badge {
  letter-spacing: 0.06em;
}

button,
input,
select,
textarea {
  font-family: inherit;
}

/* ── Animated background (full viewport) ── */
.bg-orbs {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.bg-deep {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 130% 90% at 50% -30%, rgba(92, 0, 255, 0.22), transparent 55%),
    radial-gradient(ellipse 90% 70% at 100% 40%, rgba(88, 101, 242, 0.12), transparent 50%),
    radial-gradient(ellipse 80% 60% at 0% 70%, rgba(124, 58, 237, 0.14), transparent 48%),
    radial-gradient(ellipse 60% 40% at 50% 100%, rgba(59, 7, 100, 0.35), transparent 55%),
    linear-gradient(180deg, #06060c 0%, #050508 45%, #080812 100%);
}

.bg-mesh {
  position: absolute;
  inset: -25%;
  background:
    radial-gradient(circle at 15% 25%, rgba(92, 0, 255, 0.14) 0, transparent 42%),
    radial-gradient(circle at 85% 18%, rgba(59, 130, 246, 0.1) 0, transparent 40%),
    radial-gradient(circle at 72% 78%, rgba(168, 85, 247, 0.12) 0, transparent 44%),
    radial-gradient(circle at 28% 82%, rgba(88, 101, 242, 0.08) 0, transparent 38%);
  animation: meshMove 22s ease-in-out infinite alternate;
  filter: blur(2px);
}

@keyframes meshMove {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  100% { transform: translate(-3%, 2%) scale(1.08) rotate(2deg); }
}

.bg-beams {
  position: absolute;
  inset: -40%;
  background: conic-gradient(
    from 200deg at 50% 45%,
    transparent 0deg,
    rgba(92, 0, 255, 0.07) 55deg,
    transparent 115deg,
    rgba(88, 101, 242, 0.05) 185deg,
    transparent 245deg,
    rgba(139, 92, 246, 0.06) 310deg,
    transparent 360deg
  );
  animation: beamSpin 32s linear infinite;
  opacity: 0.9;
}

@keyframes beamSpin {
  to { transform: rotate(360deg); }
}

.bg-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 85% 75% at 50% 45%, transparent 35%, rgba(5, 5, 8, 0.55) 100%);
  opacity: 0.65;
}

.bg-noise {
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

.bg-particles {
  position: absolute;
  inset: 0;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
  animation: float 20s ease-in-out infinite;
  mix-blend-mode: screen;
}

.orb-1 {
  width: 620px; height: 620px;
  background: var(--brand);
  top: -220px; left: -140px;
  animation-delay: 0s;
}

.orb-2 {
  width: 520px; height: 520px;
  background: #3b0764;
  bottom: -180px; right: -120px;
  animation-delay: -7s;
}

.orb-3 {
  width: 380px; height: 380px;
  background: var(--discord);
  top: 38%; left: 62%;
  opacity: 0.35;
  animation-delay: -14s;
}

.orb-4 {
  width: 340px; height: 340px;
  background: #a855f7;
  top: 8%; right: 12%;
  opacity: 0.28;
  animation-delay: -4s;
  animation-duration: 24s;
}

.orb-5 {
  width: 280px; height: 280px;
  background: #312e81;
  bottom: 12%; left: 8%;
  opacity: 0.32;
  animation-delay: -11s;
  animation-duration: 18s;
}

.orb-6 {
  width: 240px; height: 240px;
  background: #6366f1;
  top: 55%; left: 35%;
  opacity: 0.2;
  animation-delay: -18s;
  animation-duration: 26s;
}

.bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 64px 64px;
  animation: gridDrift 50s linear infinite;
  opacity: 0.55;
}

@keyframes gridDrift {
  from { transform: translateY(0); }
  to { transform: translateY(64px); }
}

.bg-aurora {
  position: absolute;
  inset: -30%;
  background:
    radial-gradient(circle at 18% 28%, rgba(92, 0, 255, 0.2), transparent 44%),
    radial-gradient(circle at 82% 18%, rgba(88, 101, 242, 0.16), transparent 40%),
    radial-gradient(circle at 58% 82%, rgba(168, 85, 247, 0.14), transparent 42%),
    radial-gradient(circle at 42% 52%, rgba(99, 102, 241, 0.08), transparent 50%);
  animation: auroraShift 20s ease-in-out infinite alternate;
}

@keyframes auroraShift {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); opacity: 0.75; }
  100% { transform: translate(-4%, 3%) scale(1.06) rotate(-1deg); opacity: 1; }
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -40px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}

#app { position: relative; z-index: 1; }

.hidden { display: none !important; }

.view-hidden { display: none; }
.view-active { display: block; animation: viewIn 0.5s var(--ease) both; }

@keyframes viewIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}

.animate-in { animation: viewIn 0.5s var(--ease) both; }
.delay-1 { animation-delay: 0.08s; }
.delay-2 { animation-delay: 0.16s; }
.delay-3 { animation-delay: 0.24s; }

/* ── Tooltips ── */
[data-tooltip] {
  position: relative;
  cursor: help;
}

[data-tooltip]::before,
[data-tooltip]::after {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease);
  z-index: 1000;
}

[data-tooltip]::before {
  content: attr(data-tooltip);
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  padding: 0.45rem 0.7rem;
  background: #1a1a24;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text);
  white-space: nowrap;
  max-width: 240px;
  white-space: normal;
  text-align: center;
  box-shadow: var(--shadow);
  line-height: 1.35;
}

[data-tooltip]::after {
  content: '';
  bottom: calc(100% + 2px);
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #1a1a24;
}

[data-tooltip]:hover::before,
[data-tooltip]:hover::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Tooltips near top of page — show below to avoid sticky header clip */
.header [data-tooltip]::before,
.page-intro [data-tooltip]::before,
.page-meta-row [data-tooltip]::before,
.panel-head [data-tooltip]::before,
[data-tooltip-pos="bottom"]::before {
  bottom: auto;
  top: calc(100% + 8px);
  transform: translateX(-50%) translateY(-4px);
}

.header [data-tooltip]::after,
.page-intro [data-tooltip]::after,
.page-meta-row [data-tooltip]::after,
.panel-head [data-tooltip]::after,
[data-tooltip-pos="bottom"]::after {
  bottom: auto;
  top: calc(100% + 2px);
  border-top-color: transparent;
  border-bottom-color: #1a1a24;
}

.header [data-tooltip]:hover::before,
.header [data-tooltip]:hover::after,
.page-intro [data-tooltip]:hover::before,
.page-intro [data-tooltip]:hover::after,
.page-meta-row [data-tooltip]:hover::before,
.page-meta-row [data-tooltip]:hover::after,
.panel-head [data-tooltip]:hover::before,
.panel-head [data-tooltip]:hover::after,
[data-tooltip-pos="bottom"]:hover::before,
[data-tooltip-pos="bottom"]:hover::after {
  transform: translateX(-50%) translateY(0);
}

.btn[data-tooltip]::before { white-space: normal; width: max-content; max-width: 220px; }

.card.stat {
  cursor: default;
}

/* ── Header ── */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(20px) saturate(1.2);
  position: sticky;
  top: 0;
  z-index: 50;
  background:
    linear-gradient(180deg, rgba(12, 10, 20, 0.88) 0%, rgba(9, 9, 13, 0.78) 100%);
  box-shadow: 0 1px 0 rgba(124, 58, 237, 0.08);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

.brand-mark {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 13px;
  overflow: visible;
  flex-shrink: 0;
}

.brand-mark-glow {
  position: absolute;
  inset: -4px;
  border-radius: 16px;
  background: radial-gradient(circle at 50% 50%, rgba(124, 58, 237, 0.35), transparent 70%);
  opacity: 0.85;
  pointer-events: none;
}

.brand-mark-ring {
  position: absolute;
  inset: 0;
  border-radius: 13px;
  padding: 1px;
  background: linear-gradient(145deg, rgba(167, 139, 250, 0.75), rgba(92, 0, 255, 0.35) 45%, rgba(255, 255, 255, 0.12));
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.brand-logo {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
  line-height: 1.1;
  min-width: 0;
}

.brand-name {
  font-size: 1.08rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #fff 20%, #ddd6fe 55%, #c4b5fd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.brand-sub {
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.48);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.header-actions { display: flex; align-items: center; gap: 0.75rem; position: relative; z-index: 40; }

.header-user {
  position: relative;
}

.header-user-trigger {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.32rem 0.55rem 0.32rem 0.32rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
  color: inherit;
  font: inherit;
  cursor: pointer;
  transition: transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s, background 0.25s;
  animation: headerUserIn 0.5s var(--ease) both;
}

@keyframes headerUserIn {
  from { opacity: 0; transform: translateY(-8px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

.header-user-trigger:hover,
.header-user-trigger[aria-expanded="true"] {
  border-color: rgba(92, 0, 255, 0.35);
  box-shadow: 0 8px 28px rgba(92, 0, 255, 0.18);
  transform: translateY(-1px);
}

.header-user-avatar-wrap {
  position: relative;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.header-user-avatar,
.header-user-avatar-fallback {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
}

.header-user-avatar-fallback {
  display: grid;
  place-items: center;
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.25);
  color: var(--brand-light);
}

.header-user-avatar {
  border: 2px solid rgba(92, 0, 255, 0.35);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.header-user-status {
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  border: 2px solid #0a0a10;
}

.header-user-status.is-live {
  background: var(--success);
  box-shadow: 0 0 10px rgba(67, 181, 129, 0.65);
  animation: headerLivePulse 2s ease-in-out infinite;
}

@keyframes headerLivePulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(67, 181, 129, 0.45); }
  50% { box-shadow: 0 0 0 6px rgba(67, 181, 129, 0); }
}

.header-user-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.05rem;
  min-width: 0;
  max-width: 140px;
}

.header-user-name {
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.header-user-sub {
  font-size: 0.68rem;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.header-user-chevron {
  color: var(--muted);
  transition: transform 0.25s var(--ease), color 0.25s;
  flex-shrink: 0;
}

.header-user-trigger[aria-expanded="true"] .header-user-chevron {
  transform: rotate(180deg);
  color: var(--brand-light);
}

.header-user-menu {
  position: absolute;
  top: calc(100% + 0.55rem);
  right: 0;
  min-width: 220px;
  padding: 0.45rem;
  border-radius: calc(var(--radius-sm) + 4px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(10, 10, 16, 0.92);
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(92, 0, 255, 0.08);
  animation: headerMenuIn 0.28s var(--ease) both;
  transform-origin: top right;
}

@keyframes headerMenuIn {
  from { opacity: 0; transform: translateY(-8px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

.header-user-menu-head {
  padding: 0.55rem 0.65rem 0.65rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 0.35rem;
}

.header-user-menu-label {
  display: block;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
}

.header-user-menu-name {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.88rem;
  font-weight: 700;
}

.header-user-menu-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.55rem 0.65rem;
  border: none;
  border-radius: calc(var(--radius-sm) - 2px);
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, transform 0.18s var(--ease);
}

.header-user-menu-item:hover {
  background: rgba(255, 255, 255, 0.05);
  transform: translateX(3px);
}

.header-user-menu-item--danger {
  color: #ff9a9c;
}

.header-user-menu-item--danger:hover {
  background: rgba(237, 66, 69, 0.12);
}

.header-user-menu-divider {
  height: 1px;
  margin: 0.35rem 0.25rem;
  background: rgba(255, 255, 255, 0.06);
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.35rem 0.5rem 0.35rem 0.35rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  animation: viewIn 0.4s var(--ease) both;
}

.user-chip img {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid var(--brand-dim);
}

.user-name { font-size: 0.85rem; font-weight: 600; }

/* ── Layout ── */
#main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem;
}

body.view-login-active #main {
  max-width: none;
  margin: 0;
  padding: 0;
}

body.view-login-active .header {
  background: rgba(5, 5, 8, 0.35);
  border-bottom-color: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px) saturate(1.3);
}

body.view-login-active .bg-orbs {
  opacity: 1;
}

body.view-app-active .bg-grid {
  opacity: 0.25;
}

body.view-app-active .bg-beams,
body.view-app-active .bg-particles {
  opacity: 0.35;
}

.page-intro {
  margin-bottom: 1.5rem;
  overflow: visible;
  position: relative;
  z-index: 2;
}

.page-intro-left { max-width: 100%; overflow: visible; }

.page-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.35rem;
  overflow: visible;
  position: relative;
  z-index: 2;
}

.meta-sep { color: var(--border); user-select: none; }

.refresh-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.15rem 0;
  border: none;
  background: none;
  color: var(--muted);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: color 0.2s;
  position: relative;
}

.refresh-link:hover { color: var(--brand-light); }

.refresh-link.is-loading .icon { animation: spin 0.7s linear infinite; }

.refresh-link.is-loading {
  color: var(--brand-light);
}

.refresh-link:disabled { opacity: 0.5; cursor: wait; }

.refresh-banner {
  margin-top: 0.85rem;
  animation: loadingBannerIn 0.45s var(--ease) both;
}

.loading-banner-refresh {
  border-color: rgba(92, 0, 255, 0.28);
}

.loading-banner-refresh .loading-banner-icon-wrap {
  animation: loadingIconPulse 1.2s ease-in-out infinite, spin 1.4s linear infinite;
}

body.is-refreshing .app-tab-panels {
  opacity: 0.72;
  transition: opacity 0.25s var(--ease);
}

body.is-refreshing .page-intro-left {
  opacity: 0.92;
}

.page-title {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.beta-badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(92, 0, 255, 0.35), rgba(124, 58, 237, 0.18));
  color: #ede9fe;
  border: 1px solid rgba(167, 139, 250, 0.5);
  box-shadow: 0 0 16px rgba(92, 0, 255, 0.3);
  line-height: 1;
  flex-shrink: 0;
}

.page-beta {
  font-size: 0.72rem;
  padding: 0.35rem 0.75rem;
}

.page-sub { color: var(--muted); font-size: 0.9rem; margin-top: 0.2rem; }

.gradient-text {
  background: linear-gradient(135deg, #fff 30%, var(--brand-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Cards ── */
.card {
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.glass {
  background: var(--surface);
  backdrop-filter: blur(16px);
}

/* ── Landing page ── */
.landing-scene {
  position: relative;
  min-height: calc(100vh - 65px);
  min-height: calc(100dvh - 65px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(1.5rem, 4vw, 3rem);
  width: 100%;
}

.landing-particle {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--size);
  height: var(--size);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
  box-shadow: 0 0 10px rgba(139, 92, 246, 0.55);
  animation: particleFloat var(--dur) ease-in-out infinite;
  animation-delay: var(--delay);
  opacity: 0;
}

@keyframes particleFloat {
  0%, 100% { opacity: 0; transform: translateY(0) scale(0.5); }
  15%, 85% { opacity: 0.65; }
  50% { opacity: 1; transform: translateY(-36px) scale(1); }
}

.landing-layout {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1080px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: 2rem;
  align-items: center;
}

.landing-aside {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.landing-profile {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.landing-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.landing-avatar-ring {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  background: conic-gradient(from 180deg, var(--brand), #7c3aed, var(--discord), var(--brand));
  animation: avatarRing 6s linear infinite;
}

@keyframes avatarRing {
  to { transform: rotate(360deg); }
}

.landing-avatar {
  position: relative;
  display: block;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--bg);
  background: var(--surface-2);
}

.landing-avatar-status {
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--success);
  border: 3px solid var(--bg);
  box-shadow: 0 0 10px rgba(67, 181, 129, 0.5);
}

.landing-profile-copy {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.landing-profile-name {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.landing-profile-role {
  font-size: 0.82rem;
  color: var(--muted);
}

.landing-stack-label,
.landing-credits-title {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.landing-stack-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.55rem;
}

.landing-stack-icon {
  --tech-color: var(--brand-light);
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--tech-color);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  animation: stackFloat 4.5s ease-in-out infinite;
  animation-delay: var(--float-delay);
  transition: transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s;
  cursor: default;
}

.landing-stack-icon svg {
  width: 22px;
  height: 22px;
}

.landing-stack-icon:hover {
  transform: translateY(-4px) scale(1.06);
  border-color: color-mix(in srgb, var(--tech-color) 45%, transparent);
  box-shadow: 0 8px 20px color-mix(in srgb, var(--tech-color) 20%, transparent);
}

.landing-stack-icon-label {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  padding: 0.22rem 0.45rem;
  border-radius: 6px;
  background: rgba(9, 9, 13, 0.92);
  border: 1px solid var(--border);
  font-size: 0.65rem;
  font-weight: 600;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}

.landing-stack-icon:hover .landing-stack-icon-label {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@keyframes stackFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.landing-credits {
  padding: 1rem 1.1rem;
}

.landing-credits-title {
  margin-bottom: 0.75rem;
}

.landing-credits-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.landing-credits-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.45;
}

.landing-credits-list strong {
  color: var(--text);
  font-weight: 700;
}

.landing-credit-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-top: 0.35rem;
  flex-shrink: 0;
}

.landing-credit-dot--owner { background: var(--brand-light); box-shadow: 0 0 8px var(--brand-glow); }
.landing-credit-dot--brent { background: #60a5fa; box-shadow: 0 0 8px rgba(96, 165, 250, 0.45); }
.landing-credit-dot--api { background: var(--muted); }

.landing-tilt-scene {
  perspective: 1200px;
  display: flex;
  justify-content: center;
}

.landing-tilt-card {
  position: relative;
  width: 100%;
  max-width: 480px;
  padding: 2rem 2rem 1.75rem;
  transform-style: preserve-3d;
  transition: box-shadow 0.35s var(--ease);
  will-change: transform;
  overflow: hidden;
}

.landing-card-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, 0.06) 50%, transparent 65%);
  transform: translateX(-120%);
  animation: cardShine 7s ease-in-out infinite;
  pointer-events: none;
}

@keyframes cardShine {
  0%, 70% { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}

.landing-card-glow {
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle at 50% 0%, rgba(92, 0, 255, 0.18), transparent 55%);
  pointer-events: none;
}

.landing-card-top {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.35rem;
}

.landing-card-logo {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.landing-card-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.landing-card-brand {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  min-width: 0;
  flex: 1;
}

.landing-card-name {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.landing-card-tag {
  font-size: 0.72rem;
  color: var(--muted);
}

.landing-card-badge {
  margin-left: auto;
}

.landing-title {
  position: relative;
  z-index: 1;
  font-size: 2.35rem;
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.04em;
  margin-bottom: 0.85rem;
}

.landing-desc {
  position: relative;
  z-index: 1;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.65;
  margin-bottom: 1.35rem;
}

.landing-features {
  position: relative;
  z-index: 1;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-bottom: 1.5rem;
}

.landing-features li {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.76rem;
  font-weight: 600;
  padding: 0.38rem 0.7rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
}

.landing-features .icon { color: var(--brand-light); }

.landing-cta {
  position: relative;
  z-index: 1;
}

.landing-footnote {
  position: relative;
  z-index: 1;
  margin-top: 1rem;
  text-align: center;
  font-size: 0.72rem;
  color: var(--muted);
}

.landing-tilt-scene:hover .landing-tilt-card {
  box-shadow: 0 24px 64px rgba(92, 0, 255, 0.22), 0 0 0 1px rgba(139, 92, 246, 0.15);
}

@media (max-width: 900px) {
  .landing-layout {
    grid-template-columns: 1fr;
    max-width: 520px;
  }

  .landing-aside {
    order: 2;
  }

  .landing-tilt-scene {
    order: 1;
  }

  .landing-stack-icons {
    justify-content: center;
  }

  .landing-profile {
    justify-content: center;
    text-align: center;
  }

  .landing-profile-copy {
    align-items: center;
  }
}

@media (max-width: 640px) {
  .landing-scene {
    min-height: calc(100vh - 58px);
    min-height: calc(100dvh - 58px);
    padding: 1.25rem 1rem 2rem;
  }

  .landing-title {
    font-size: 1.85rem;
  }

  .landing-tilt-card {
    padding: 1.5rem 1.35rem 1.35rem;
  }
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-sm);
  border: none;
  font: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: transform 0.2s var(--ease-bounce), box-shadow 0.2s, background 0.2s;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(255,255,255,0.1), transparent);
  opacity: 0;
  transition: opacity 0.2s;
}

.btn-primary:hover::after,
.btn-discord:hover::after { opacity: 1; }

.btn-ghost::after,
.refresh-link::after { display: none; }
.btn:hover { transform: translateY(-2px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; }

.btn-lg { padding: 0.85rem 1.5rem; font-size: 1rem; width: 100%; }
.btn-primary {
  background: linear-gradient(135deg, var(--brand), #7c3aed);
  color: white;
  box-shadow: 0 4px 20px var(--brand-glow);
}
.btn-primary:hover { box-shadow: 0 8px 28px var(--brand-glow); }
.btn-discord {
  background: linear-gradient(135deg, var(--discord), #4752c4);
  color: white;
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(88, 101, 242, 0.35);
}
.btn-ghost {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-sm { padding: 0.4rem 0.85rem; font-size: 0.82rem; }

.icon-refresh { display: none; }

/* ── Icons ── */
.icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.icon svg { width: 100%; height: 100%; display: block; }

.icon-sm { width: 16px; height: 16px; }

.icon-lg { width: 24px; height: 24px; }

.stat-icon .icon { color: var(--brand-light); }

.search-icon-svg {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}

/* ── V-Bucks ── */
.vbucks {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  vertical-align: middle;
}

.vbuck-img {
  display: block;
  width: 16px;
  height: 16px;
  max-width: 16px;
  max-height: 16px;
  object-fit: contain;
  flex-shrink: 0;
}

.vbuck-amt { font-weight: 700; }

.vbuck-label {
  font-size: 0.85em;
  color: var(--muted);
  font-weight: 500;
}

.vbucks-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  white-space: nowrap;
}

.vbucks-inline .vbuck-img {
  flex: 0 0 auto;
  position: static;
  width: 14px;
  height: 14px;
  max-width: 14px;
  max-height: 14px;
}

.vbucks-inline .vbuck-amt {
  flex: 0 1 auto;
  line-height: 1;
}

.shop-card-price .vbucks { color: var(--brand-light); }

.stat-value .vbucks .vbuck-amt { font-size: inherit; }

/* ── App tabs ── */
.app-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0.45rem;
  margin-bottom: 1.25rem;
}

.app-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease);
}

.app-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.app-tab.active {
  color: var(--text);
  background: rgba(124, 58, 237, 0.14);
  border-color: rgba(124, 58, 237, 0.35);
  box-shadow: inset 0 0 0 1px rgba(124, 58, 237, 0.12);
}

.app-tab-badge {
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.15rem;
  text-align: center;
}

.app-tab-panels {
  display: block;
}

.app-tab-panel {
  animation: tabIn 0.28s var(--ease) both;
}

.app-tab-panel[hidden] {
  display: none !important;
}

@keyframes tabIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* ── Overview dashboard ── */
.overview-shell {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.overview-hero {
  position: relative;
  overflow: hidden;
  padding: 1.35rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "main cards"
    "main actions";
  gap: 1rem 1.25rem;
  align-items: start;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(135deg, rgba(88, 101, 242, 0.12) 0%, transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
}

.overview-hero-glow {
  position: absolute;
  top: -40%;
  right: -8%;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(92, 0, 255, 0.18), transparent 70%);
  pointer-events: none;
}

.overview-hero-main {
  grid-area: main;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  min-width: 0;
  position: relative;
  z-index: 1;
}

.overview-hero-avatar {
  position: relative;
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
}

.overview-hero-avatar-ring {
  position: absolute;
  inset: 0;
  border-radius: 18px;
  border: 1px solid rgba(92, 0, 255, 0.35);
  background: rgba(92, 0, 255, 0.12);
}

.overview-hero-avatar-icon {
  position: relative;
  z-index: 1;
  color: var(--brand-light);
}

.overview-hero-eyebrow {
  margin: 0 0 0.25rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.overview-hero-title {
  margin: 0 0 0.35rem;
  font-size: clamp(1.25rem, 2.5vw, 1.65rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.overview-hero-sub {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.overview-hero-cards {
  grid-area: cards;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  position: relative;
  z-index: 1;
}

.overview-hero-card {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 132px;
  padding: 0.8rem 0.95rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.overview-hero-card.is-primary {
  border-color: rgba(92, 0, 255, 0.35);
  background: linear-gradient(180deg, rgba(92, 0, 255, 0.14), rgba(255, 255, 255, 0.03));
}

.overview-hero-card-label {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.overview-hero-card-value {
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--text);
}

.overview-hero-actions {
  grid-area: actions;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  position: relative;
  z-index: 1;
}

.overview-hero-skeleton {
  grid-column: 1 / -1;
  padding: 0.25rem 0;
}

.overview-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.85rem;
}

.overview-metrics .loading-banner-stats {
  grid-column: 1 / -1;
}

.overview-metric {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 1rem 1.05rem;
  border-radius: calc(var(--radius) + 2px);
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
  transition: transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s;
  animation: statIn 0.45s var(--ease) both;
}

.overview-metric:nth-child(1) { animation-delay: 0.05s; }
.overview-metric:nth-child(2) { animation-delay: 0.1s; }
.overview-metric:nth-child(3) { animation-delay: 0.15s; }
.overview-metric:nth-child(4) { animation-delay: 0.2s; }
.overview-metric:nth-child(5) { animation-delay: 0.25s; }

.overview-metric:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
}

.overview-metric-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--brand-light);
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.2);
}

.overview-metric--balance .overview-metric-icon {
  background: linear-gradient(145deg, rgba(92, 0, 255, 0.22), rgba(92, 0, 255, 0.08));
}

.overview-metric--slots .overview-metric-icon {
  color: #93c5fd;
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.22);
}

.overview-metric--security.overview-metric--ok .overview-metric-icon {
  color: var(--success);
  background: rgba(67, 181, 129, 0.12);
  border-color: rgba(67, 181, 129, 0.22);
}

.overview-metric--security.overview-metric--warn .overview-metric-icon {
  color: var(--warning);
  background: var(--warning-dim);
  border-color: rgba(255, 102, 0, 0.22);
}

.overview-metric-body {
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  min-width: 0;
  flex: 1;
}

.overview-metric-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}

.overview-metric-value {
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.overview-metric-value-split {
  display: flex;
  align-items: baseline;
  gap: 0.2rem;
}

.overview-metric-value-main {
  font-size: 1.18rem;
}

.overview-metric-value-denom {
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 700;
}

.overview-metric-value-text {
  font-size: 1.02rem;
}

.overview-metric-sub {
  font-size: 0.76rem;
  color: var(--muted);
  line-height: 1.4;
}

.overview-metric-bar {
  margin-top: 0.45rem;
  height: 4px;
  background: var(--surface-2);
  border-radius: 999px;
  overflow: hidden;
}

.overview-metric-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, var(--brand-light));
  border-radius: 999px;
  transition: width 0.8s var(--ease);
}

.overview-metric-badge {
  display: inline-flex;
  align-items: center;
  margin-top: 0.25rem;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  align-self: flex-start;
}

.overview-metric-badge.ok { background: var(--success-dim); color: var(--success); }
.overview-metric-badge.warn { background: var(--warning-dim); color: var(--warning); }
.overview-metric-badge.locked { background: var(--error-dim); color: var(--error); }

.overview-metric-skeleton {
  pointer-events: none;
}

.overview-alerts {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.overview-alert {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  flex-wrap: wrap;
  padding: 0.95rem 1.1rem;
  border-radius: calc(var(--radius) + 2px);
  animation: viewIn 0.4s var(--ease) both;
}

.overview-alert--warn {
  background: var(--warning-dim);
  border: 1px solid rgba(255, 102, 0, 0.25);
  color: #ffb366;
}

.overview-alert-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: rgba(0, 0, 0, 0.15);
}

.overview-alert-copy {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  flex: 1;
  min-width: min(100%, 240px);
}

.overview-alert-copy strong {
  color: var(--text);
  font-size: 0.88rem;
}

.overview-alert-copy span {
  font-size: 0.84rem;
  line-height: 1.45;
}

.overview-session {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.overview-recent {
  padding: 0;
  overflow: hidden;
}

.overview-recent-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.35rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.overview-recent-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

.overview-recent-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--brand-light);
  background: linear-gradient(135deg, rgba(92, 0, 255, 0.22), rgba(92, 0, 255, 0.06));
  border: 1px solid rgba(92, 0, 255, 0.25);
}

/* ── Stats (legacy fallback) ── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.stat {
  padding: 1.15rem 1.25rem;
  transition: transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s;
  animation: statIn 0.45s var(--ease) both;
  overflow: visible;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat:nth-child(1) { animation-delay: 0.05s; }
.stat:nth-child(2) { animation-delay: 0.1s; }
.stat:nth-child(3) { animation-delay: 0.15s; }
.stat:nth-child(4) { animation-delay: 0.2s; }
.stat:nth-child(5) { animation-delay: 0.25s; }

@keyframes statIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

.stat:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.stat-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  width: 100%;
  margin-bottom: 0.55rem;
}

.stat-icon { font-size: 1.1rem; opacity: 0.85; }

.stat-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  font-weight: 600;
}

.stat-value {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.15rem;
  width: 100%;
}

.stat-value .vbucks {
  justify-content: center;
}

.stat-value-split {
  align-items: baseline;
  gap: 0.2rem;
}

.stat-value-main {
  font-size: 1.4rem;
}

.stat-value-denom {
  font-size: 0.85rem;
  color: var(--muted);
  font-weight: 700;
}

.stat-sub {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.35rem;
  line-height: 1.4;
  max-width: 16rem;
}

.stat-bar {
  margin-top: 0.65rem;
  height: 4px;
  background: var(--surface-2);
  border-radius: 999px;
  overflow: hidden;
  width: 100%;
}

.stat-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  border-radius: 999px;
  transition: width 0.8s var(--ease);
}

.stat-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
}

.stat-badge.ok { background: var(--success-dim); color: var(--success); }
.stat-badge.warn { background: var(--warning-dim); color: var(--warning); }
.stat-badge.locked { background: var(--error-dim); color: var(--error); }

/* ── Alerts ── */
.alert-banner {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  animation: viewIn 0.4s var(--ease) both;
}

.alert-warn {
  background: var(--warning-dim);
  border: 1px solid rgba(255, 102, 0, 0.25);
  color: #ffb366;
}

.alert-error {
  background: var(--error-dim);
  border: 1px solid rgba(237, 66, 69, 0.25);
  color: #ff9a9c;
}

.account-locked-panel {
  margin-bottom: 1rem;
  padding: 1.5rem;
  border: 1px solid rgba(237, 66, 69, 0.28);
  background: linear-gradient(135deg, rgba(237, 66, 69, 0.08), rgba(88, 101, 242, 0.04));
}

.account-locked-shell {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.account-locked-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--error);
  background: var(--error-dim);
  border: 1px solid rgba(237, 66, 69, 0.25);
}

.account-locked-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--error);
  background: var(--error-dim);
  margin-bottom: 0.55rem;
}

.account-locked-title {
  margin: 0 0 0.45rem;
  font-size: 1.35rem;
}

.account-locked-body,
.account-locked-foot {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.55;
}

.account-locked-body {
  margin-bottom: 0.65rem;
}

.account-locked-foot {
  font-size: 0.92rem;
}

.alert-ok {
  background: rgba(67, 181, 129, 0.1);
  border: 1px solid rgba(67, 181, 129, 0.28);
  color: #8ee4bc;
}

/* ── Gifting session panel ── */
.session-panel {
  position: relative;
  overflow: hidden;
  border-radius: calc(var(--radius) + 4px);
  border: 1px solid rgba(67, 181, 129, 0.2);
  background:
    linear-gradient(135deg, rgba(67, 181, 129, 0.1) 0%, rgba(92, 0, 255, 0.06) 55%, rgba(22, 22, 30, 0.92) 100%);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  animation: viewIn 0.45s var(--ease) both;
}

.session-panel-glow {
  position: absolute;
  inset: -30% auto auto -10%;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(67, 181, 129, 0.22), transparent 68%);
  pointer-events: none;
}

.session-panel-body {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 1.25rem;
  padding: 1.15rem 1.25rem;
}

.session-panel-main {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 0;
}

.session-panel-icon-wrap {
  position: relative;
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
}

.session-panel-icon-ring {
  position: absolute;
  inset: 0;
  border-radius: 16px;
  border: 1px solid rgba(67, 181, 129, 0.35);
  background: rgba(67, 181, 129, 0.1);
  animation: sessionRingPulse 2.8s ease-in-out infinite;
}

@keyframes sessionRingPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(67, 181, 129, 0.25); }
  50% { box-shadow: 0 0 0 8px rgba(67, 181, 129, 0); }
}

.session-panel-icon {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--success);
}

.session-panel-icon .icon {
  color: inherit;
}

.session-panel-copy {
  min-width: 0;
}

.session-panel-headline {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  margin-bottom: 0.45rem;
}

.session-panel-title {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
}

.session-panel-live {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--success);
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  background: rgba(67, 181, 129, 0.12);
  border: 1px solid rgba(67, 181, 129, 0.25);
}

.session-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px rgba(67, 181, 129, 0.8);
  animation: sessionLiveBlink 1.8s ease-in-out infinite;
}

@keyframes sessionLiveBlink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.85); }
}

.session-credits-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.session-credit-dots {
  display: inline-flex;
  gap: 0.3rem;
}

.session-credit-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: background 0.25s, box-shadow 0.25s;
}

.session-credit-dot.is-filled {
  background: linear-gradient(135deg, #43b581, #34d399);
  border-color: rgba(67, 181, 129, 0.5);
  box-shadow: 0 0 8px rgba(67, 181, 129, 0.45);
}

.session-credits-label {
  font-size: 0.78rem;
  color: var(--muted);
}

.session-panel-countdown {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  min-width: 11rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.28);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.session-countdown-top {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.session-countdown-label {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.session-countdown-value {
  font-size: 1.35rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  color: var(--text);
  line-height: 1;
}

.session-countdown-track {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.session-countdown-fill {
  height: 100%;
  width: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #43b581, #8b5cf6);
  transition: width 1s linear;
}

.session-countdown-hint {
  font-size: 0.65rem;
  color: rgba(139, 139, 160, 0.9);
  line-height: 1.35;
}

.session-panel-countdown.is-urgent {
  border-color: rgba(255, 102, 0, 0.35);
  background: rgba(255, 102, 0, 0.08);
}

.session-panel-countdown.is-urgent .session-countdown-value {
  color: #ffb366;
}

.session-panel-countdown.is-urgent .session-countdown-fill {
  background: linear-gradient(90deg, #ff6600, #ff9944);
}

.session-panel-countdown.is-expired .session-countdown-value {
  color: var(--error);
}

.session-panel-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.55rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.2s, border-color 0.2s, background 0.2s, transform 0.2s var(--ease);
}

.session-panel-action:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  transform: translateY(-1px);
}

.session-panel-action .icon {
  color: var(--brand-light);
}

.alert-banner code {
  background: rgba(0,0,0,0.25);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  font-size: 0.85em;
}

/* ── Shop panel ── */
.panel {
  padding: 1.35rem;
  overflow: visible;
}

.panel-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
  overflow: visible;
}

.panel-title { font-size: 1.15rem; font-weight: 700; }

.panel-sub {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.search-wrap {
  position: relative;
  flex: 1 1 200px;
  min-width: 0;
  max-width: min(360px, 100%);
}

.search-wrap input {
  width: 100%;
  padding: 0.65rem 2.25rem 0.65rem 2.25rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-wrap input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-dim);
}

.search-clear {
  position: absolute;
  right: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  border: none;
  background: var(--surface-hover);
  color: var(--muted);
  border-radius: 50%;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  transition: background 0.15s, color 0.15s;
}

.search-clear:hover { background: var(--brand-dim); color: var(--text); }

.shop-meta-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  color: var(--muted);
  min-height: 1.25rem;
  padding-bottom: 0.85rem;
}

.shop-meta-count { color: var(--text); font-weight: 600; }

.shop-meta-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.shop-meta-chip--ok {
  color: #86efac;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.22);
}

.shop-meta-dot { opacity: 0.45; }

.shop-meta-sync { color: var(--muted); }

/* ── Loading banners ── */
.loading-banner {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(92, 0, 255, 0.2);
  background: linear-gradient(135deg, rgba(92, 0, 255, 0.1), rgba(92, 0, 255, 0.03));
  animation: loadingBannerIn 0.5s var(--ease) both;
}

.loading-banner-stats {
  grid-column: 1 / -1;
  margin-bottom: 0.25rem;
}

.loading-banner-inline {
  margin-bottom: 0.15rem;
}

@keyframes loadingBannerIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.loading-banner-glow {
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle, rgba(92, 0, 255, 0.18), transparent 55%);
  animation: loadingGlow 2.4s ease-in-out infinite;
  pointer-events: none;
}

@keyframes loadingGlow {
  0%, 100% { transform: translate(-10%, -10%); opacity: 0.6; }
  50% { transform: translate(10%, 10%); opacity: 1; }
}

.loading-banner-inner {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.9rem 1rem;
  position: relative;
  z-index: 1;
}

.loading-banner-icon-wrap {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.25);
  display: grid;
  place-items: center;
  color: var(--brand-light);
  flex-shrink: 0;
  animation: loadingIconPulse 1.6s ease-in-out infinite;
}

@keyframes loadingIconPulse {
  0%, 100% { box-shadow: 0 0 0 rgba(92, 0, 255, 0); transform: scale(1); }
  50% { box-shadow: 0 0 20px var(--brand-glow); transform: scale(1.04); }
}

.loading-banner-copy {
  flex: 1;
  min-width: 0;
}

.loading-banner-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}

.loading-banner-sub {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.loading-dots {
  display: flex;
  gap: 0.3rem;
  align-items: center;
  flex-shrink: 0;
}

.loading-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand-light);
  animation: loadingDot 1.2s ease-in-out infinite;
}

.loading-dots span:nth-child(2) { animation-delay: 0.15s; }
.loading-dots span:nth-child(3) { animation-delay: 0.3s; }

@keyframes loadingDot {
  0%, 80%, 100% { transform: scale(0.65); opacity: 0.35; }
  40% { transform: scale(1); opacity: 1; }
}

.loading-banner-track {
  height: 3px;
  background: rgba(0, 0, 0, 0.25);
  overflow: hidden;
}

.loading-banner-track-fill {
  height: 100%;
  width: 35%;
  background: linear-gradient(90deg, transparent, var(--brand-light), transparent);
  animation: loadingTrack 1.4s ease-in-out infinite;
}

@keyframes loadingTrack {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(320%); }
}

/* ── Skeleton stats ── */
.skeleton-stat {
  pointer-events: none;
  animation: skeletonStatIn 0.45s var(--ease) both;
  animation-delay: calc(var(--skeleton-i) * 0.07s + 0.1s);
}

@keyframes skeletonStatIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.skeleton-stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.skeleton-icon {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: var(--surface-hover);
}

.skeleton-line {
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--surface-2) 20%, var(--surface-hover) 50%, var(--surface-2) 80%);
  background-size: 200% 100%;
  animation: skeleton 1.3s ease-in-out infinite;
  margin-bottom: 0.45rem;
}

.skeleton-line-label { width: 45%; height: 8px; margin-bottom: 0; }
.skeleton-line-value { width: 70%; height: 18px; margin-top: 0.25rem; }
.skeleton-line-sub { width: 55%; height: 8px; margin-bottom: 0; }
.skeleton-line-short { width: 40%; margin-bottom: 0; }

/* ── Skeleton shop ── */
.shop-card-skeleton {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 2px);
  overflow: hidden;
  animation: skeletonStatIn 0.45s var(--ease) both;
  animation-delay: calc(var(--skeleton-i) * 0.04s + 0.08s);
}

.shop-card-skeleton-media {
  aspect-ratio: 1;
  background: linear-gradient(135deg, var(--surface-hover) 0%, rgba(92, 0, 255, 0.06) 50%, var(--surface-hover) 100%);
  background-size: 200% 200%;
  animation: skeletonImg 1.6s ease-in-out infinite;
}

.shop-card-skeleton-body {
  padding: 0.85rem 0.9rem 1rem;
}

.shop-card-skeleton-body .skeleton-line {
  height: 9px;
  margin-bottom: 0.45rem;
}

.shop-card-skeleton-body .skeleton-line:first-child { width: 72%; }
.shop-card-skeleton-body .skeleton-line-short { width: 48%; }
.shop-card-skeleton-body .skeleton-line-label { width: 36%; margin-bottom: 0; }

.shop-card.is-loading {
  pointer-events: none;
  opacity: 0.72;
}

.shop-card.is-loading .shop-card-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(9, 9, 13, 0.55);
  z-index: 4;
}

.shop-card.is-loading .shop-card-media::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 28px;
  margin: -14px 0 0 -14px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--brand-light);
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
  z-index: 5;
}

.gift-confirm-actions.is-loading {
  opacity: 0.55;
  pointer-events: none;
}

/* ── Flow shell (gift preview, send pipeline, 2FA) ── */
.flow-glow {
  position: absolute;
  inset: 0 0 auto;
  height: 140px;
  background: radial-gradient(ellipse 80% 100% at 50% -20%, rgba(92, 0, 255, 0.35), transparent 70%);
  pointer-events: none;
}

.flow-shell,
.flow-modal-shell,
.auth-shell {
  position: relative;
  overflow: hidden;
}

.flow-shell {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  text-align: center;
}

.flow-hero {
  position: relative;
  width: 72px;
  height: 72px;
  margin: 0 auto 1rem;
}

.flow-hero-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(92, 0, 255, 0.25);
}

.flow-hero-loading .flow-hero-ring {
  border-color: transparent;
  border-top-color: var(--brand-light);
  border-right-color: var(--brand);
  animation: flowRingSpin 1s linear infinite;
}

.flow-hero-ring.is-success { border-color: var(--success); animation: none; box-shadow: 0 0 24px rgba(67, 181, 129, 0.35); }
.flow-hero-ring.is-error { border-color: var(--error); animation: none; box-shadow: 0 0 24px rgba(237, 66, 69, 0.35); }
.flow-hero-ring.is-warn { border-color: var(--warning); animation: none; box-shadow: 0 0 24px rgba(255, 102, 0, 0.35); }

@keyframes flowRingSpin {
  to { transform: rotate(360deg); }
}

.flow-hero-icon {
  position: absolute;
  inset: 10px;
  border-radius: 16px;
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.3);
  display: grid;
  place-items: center;
  color: var(--brand-light);
  box-shadow: 0 0 28px var(--brand-glow);
}

.flow-hero-confirm .flow-hero-icon {
  position: relative;
  inset: auto;
  width: 72px;
  height: 72px;
  margin: 0 auto;
}

.flow-header h3 {
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.35rem;
}

.flow-tag {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--brand-light);
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.25);
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  margin-bottom: 0.65rem;
}

.flow-sub {
  margin: 0 auto 1.1rem;
  max-width: 32ch;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.flow-item-chip {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-align: left;
}

.flow-item-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.flow-item-name {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.35;
}

.flow-track {
  height: 4px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 1.15rem;
}

.flow-track-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  transition: width 0.55s var(--ease);
  box-shadow: 0 0 16px var(--brand-glow);
}

.flow-track-fill.is-success { background: linear-gradient(90deg, var(--success), #5dd39e); box-shadow: 0 0 16px rgba(67, 181, 129, 0.4); }
.flow-track-fill.is-warn { background: linear-gradient(90deg, var(--warning), #ffb366); box-shadow: 0 0 16px rgba(255, 102, 0, 0.35); }
.flow-track-fill.is-error { background: linear-gradient(90deg, var(--error), #ff7b7d); box-shadow: 0 0 16px rgba(237, 66, 69, 0.35); }

.flow-steps {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  text-align: left;
}

.flow-steps-compact .flow-step-copy {
  padding-top: 0.1rem;
}

.flow-step {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.75rem;
  align-items: start;
  padding: 0.65rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  opacity: 0.45;
  transform: translateY(6px);
  transition: opacity 0.35s, transform 0.35s var(--ease), border-color 0.35s, background 0.35s;
}

.flow-step.is-enter {
  animation: flowStepEnter 0.45s var(--ease) both;
  animation-delay: calc(var(--step-i) * 0.07s);
}

@keyframes flowStepEnter {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 0.45; transform: translateY(0); }
}

.flow-step.is-pending { opacity: 0.35; }

.flow-step.is-active {
  opacity: 1;
  transform: none;
  background: rgba(92, 0, 255, 0.08);
  border-color: rgba(92, 0, 255, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.flow-step.is-done {
  opacity: 0.9;
  transform: none;
}

.flow-step-rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100%;
}

.flow-step-dot {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  display: grid;
  place-items: center;
  color: var(--muted);
  transition: border-color 0.3s, background 0.3s, color 0.3s, box-shadow 0.3s;
}

.flow-step.is-active .flow-step-dot {
  border-color: var(--brand);
  background: var(--brand-dim);
  color: var(--brand-light);
  box-shadow: 0 0 18px var(--brand-glow);
}

.flow-step.is-done .flow-step-dot {
  border-color: rgba(67, 181, 129, 0.45);
  background: var(--success-dim);
  color: var(--success);
}

.flow-step-line {
  flex: 1;
  width: 2px;
  min-height: 12px;
  margin-top: 0.35rem;
  background: var(--border);
  border-radius: 999px;
}

.flow-step.is-done .flow-step-line {
  background: linear-gradient(180deg, var(--success), rgba(67, 181, 129, 0.2));
}

.flow-step-label {
  font-size: 0.88rem;
  font-weight: 700;
}

.flow-step-detail {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.flow-step.is-active .flow-step-detail { color: var(--brand-light); }

.flow-step-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  opacity: 0;
  transform: scale(0.6);
  color: var(--success);
  transition: opacity 0.3s, transform 0.3s var(--ease-bounce);
}

.flow-step.is-done .flow-step-check {
  opacity: 1;
  transform: scale(1);
}

.flow-step.just-done .flow-step-dot {
  animation: flowDonePop 0.45s var(--ease-bounce) both;
}

@keyframes flowDonePop {
  0% { transform: scale(0.85); }
  60% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

.flow-shell-confirm .gift-confirm-card {
  width: 100%;
  margin-top: 0.25rem;
}

.modal-flow {
  width: min(500px, calc(100vw - 2rem));
}

.flow-inner {
  padding: 1.5rem 1.65rem 1.25rem;
}

.flow-modal-shell.is-outcome .flow-hero-loading .flow-hero-ring {
  animation: none;
}

.flow-outcome-wrap {
  animation: flowOutcomeIn 0.45s var(--ease) both;
}

.flow-outcome-wrap.hidden,
.flow-actions.hidden {
  display: none !important;
}

@keyframes flowOutcomeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

.flow-outcome-receipt {
  width: 100%;
  background: rgba(0, 0, 0, 0.22);
  border: 1px solid rgba(67, 181, 129, 0.25);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.flow-outcome-message {
  padding: 1rem 1.1rem;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border);
  text-align: left;
}

.flow-outcome-error .flow-outcome-message {
  border-color: rgba(237, 66, 69, 0.3);
  background: var(--error-dim);
}

.flow-outcome-warn .flow-outcome-message {
  border-color: rgba(255, 102, 0, 0.3);
  background: var(--warning-dim);
}

.flow-outcome-title {
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.35rem;
}

.flow-outcome-body {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.45;
}

.flow-outcome-body strong { color: var(--text); }

.flow-outcome-footer {
  font-size: 0.76rem;
  color: var(--muted);
  margin-top: 0.45rem;
}

.flow-actions {
  padding: 1rem 1.65rem 1.5rem;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
}

/* ── Auth modal ── */
.modal-auth {
  width: min(440px, calc(100vw - 2rem));
}

.auth-inner {
  padding: 1.65rem 1.75rem 1.5rem;
  text-align: center;
}

.auth-hero {
  position: relative;
  width: 76px;
  height: 76px;
  margin: 0 auto 1rem;
}

.auth-hero-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(92, 0, 255, 0.2);
  box-shadow: 0 0 30px rgba(92, 0, 255, 0.15);
}

.auth-hero-icon {
  position: absolute;
  inset: 10px;
  border-radius: 18px;
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.28);
  display: grid;
  place-items: center;
  color: var(--brand-light);
}

.auth-inner h3 {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
}

.auth-inner p {
  margin-bottom: 1.15rem;
}

.auth-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
  padding: 0;
  margin-top: 0.75rem;
  border-top: none;
  background: none;
}

.auth-actions .btn {
  width: 100%;
  justify-content: center;
}

.auth-actions-wrap {
  padding: 1rem 1.75rem 1.5rem;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
}

.auth-actions-wrap.hidden,
#auth-phase-pipeline.hidden,
#auth-phase-form.hidden {
  display: none !important;
}

.auth-shell.flow-modal-shell.is-outcome .flow-hero-loading .flow-hero-ring {
  animation: none;
}

.auth-outcome-receipt {
  border-color: rgba(67, 181, 129, 0.25);
}

#form-2fa .auth-actions {
  padding-left: 0;
  padding-right: 0;
  padding-bottom: 0;
  border-top: none;
  background: none;
  margin-top: 0.5rem;
}

.spinner-dark {
  border-color: rgba(255, 255, 255, 0.15);
  border-top-color: var(--brand-light);
}

.spinner-lg {
  width: 36px;
  height: 36px;
  border-width: 3px;
}

@keyframes skeletonImg {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* ── Shop panel ── */
.shop-panel {
  padding: 0;
  overflow: hidden;
}

.shop-hero {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.35rem 1.35rem 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(135deg, rgba(92, 0, 255, 0.14) 0%, transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
}

.shop-hero-glow {
  position: absolute;
  top: -45%;
  left: -5%;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(92, 0, 255, 0.2), transparent 70%);
  pointer-events: none;
}

.shop-hero-main {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  min-width: min(100%, 320px);
  flex: 1 1 320px;
  position: relative;
  z-index: 1;
}

.shop-hero-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: #fff;
  background: linear-gradient(145deg, rgba(92, 0, 255, 0.55), rgba(124, 58, 237, 0.35));
  border: 1px solid rgba(167, 139, 250, 0.35);
  box-shadow: 0 8px 24px rgba(92, 0, 255, 0.25);
}

.shop-hero-copy .panel-title {
  margin-bottom: 0.35rem;
}

.shop-hero-copy .panel-sub {
  max-width: 34rem;
  line-height: 1.5;
}

.shop-hero-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  position: relative;
  z-index: 1;
}

.shop-hero-card {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 148px;
  padding: 0.85rem 1rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.shop-hero-card.is-primary {
  border-color: rgba(92, 0, 255, 0.35);
  background: linear-gradient(180deg, rgba(92, 0, 255, 0.14), rgba(255, 255, 255, 0.03));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.shop-hero-card-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.shop-hero-card-value {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem;
  font-size: 1.02rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  line-height: 1.2;
}

.shop-hero-card-value--ok { color: #86efac; }
.shop-hero-card-value--warn { color: #fcd34d; }
.shop-hero-card-value--muted { color: var(--muted); font-size: 0.88rem; font-weight: 600; }

.shop-hero-card-denom {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--muted);
}

.shop-hero-card-hint {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.35;
}

.shop-hero-unlock {
  align-self: flex-start;
  margin-top: 0.35rem;
}

.shop-controls {
  position: sticky;
  top: 0.75rem;
  z-index: 20;
  margin: 0 0.85rem;
  padding: 0.85rem 0.85rem 0;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(9, 9, 13, 0.82);
  backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.shop-controls-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.shop-controls-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
}

.shop-density {
  display: inline-flex;
  padding: 0.18rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.shop-density-btn {
  border: none;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.shop-density-btn.is-active {
  background: var(--brand-dim);
  color: var(--text);
  box-shadow: inset 0 0 0 1px rgba(92, 0, 255, 0.2);
}

.shop-search {
  flex: 1 1 240px;
  max-width: min(420px, 100%);
}

.shop-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.shop-filters-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  flex: 1;
}

.shop-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
}

.shop-price-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.shop-price-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.38rem 0.7rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
  font: inherit;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  white-space: nowrap;
}

.shop-price-chip:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.shop-price-chip.is-active {
  background: var(--brand-dim);
  border-color: rgba(92, 0, 255, 0.45);
  color: var(--text);
  box-shadow: 0 0 0 1px rgba(92, 0, 255, 0.15);
}

.shop-reset {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.42rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font: inherit;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  white-space: nowrap;
}

.shop-reset:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.14);
  background: var(--surface-hover);
}

.shop-price-filter {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.28rem 0.45rem 0.28rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  flex-shrink: 0;
}

.shop-price-filter:focus-within,
.shop-price-filter.is-active {
  border-color: rgba(92, 0, 255, 0.45);
  background: var(--brand-dim);
  box-shadow: 0 0 0 1px rgba(92, 0, 255, 0.15);
}

.shop-price-filter-label {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted);
  line-height: 1;
}

.shop-price-filter input {
  width: 4.5rem;
  border: none;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.12rem 0;
  outline: none;
}

.shop-price-filter input::placeholder {
  color: var(--muted);
  font-weight: 500;
}

.shop-price-filter input::-webkit-outer-spin-button,
.shop-price-filter input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.shop-price-filter input[type='number'] {
  -moz-appearance: textfield;
}

.shop-price-clear {
  width: 20px;
  height: 20px;
  border: none;
  border-radius: 50%;
  background: var(--surface-hover);
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.15s, color 0.15s;
}

.shop-price-clear:hover {
  background: var(--brand-dim);
  color: var(--text);
}

.shop-filter {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.42rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s var(--ease);
  white-space: nowrap;
}

.shop-filter:hover {
  background: var(--surface-hover);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.12);
}

.shop-filter.is-active {
  background: var(--brand-dim);
  border-color: rgba(92, 0, 255, 0.45);
  color: var(--text);
  box-shadow: 0 0 0 1px rgba(92, 0, 255, 0.15);
}

.shop-filter-icon { opacity: 0.85; }

.shop-filter-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.35rem;
  height: 1.15rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.66rem;
  font-weight: 800;
  color: var(--muted);
  line-height: 1;
}

.shop-filter.is-active .shop-filter-count {
  background: rgba(92, 0, 255, 0.25);
  color: var(--brand-light);
}

.shop-sort {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.shop-sort-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.shop-sort select {
  appearance: none;
  padding: 0.45rem 1.75rem 0.45rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238b8ba0' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 0.65rem center;
  color: var(--text);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.shop-sort select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-dim);
}

/* ── Shop grid ── */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(168px, 1fr));
  gap: 0.85rem;
  padding: 1rem 1.35rem 1.35rem;
}

@media (min-width: 900px) {
  .shop-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (min-width: 1180px) {
  .shop-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

.shop-grid--compact {
  gap: 0.65rem;
}

@media (min-width: 900px) {
  .shop-grid--compact {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (min-width: 1180px) {
  .shop-grid--compact {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

.shop-grid--loading {
  padding-top: 0;
}

@keyframes itemIn {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.shop-card {
  animation: itemIn 0.42s var(--ease) both;
}

.shop-card-btn {
  width: 100%;
  border: none;
  background: none;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  padding: 0;
  border-radius: calc(var(--radius) + 2px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
  transition: transform 0.28s var(--ease), border-color 0.25s, box-shadow 0.25s;
}

.shop-card-btn:hover,
.shop-card-btn:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(92, 0, 255, 0.38);
  box-shadow: 0 14px 36px rgba(92, 0, 255, 0.16);
  outline: none;
}

.shop-card-btn.is-disabled {
  cursor: not-allowed;
}

.shop-card--no-balance,
.shop-card--no-slots,
.shop-card--locked,
.shop-card--unregistered {
  opacity: 0.82;
}

.shop-card--no-balance .shop-card-media,
.shop-card--no-slots .shop-card-media,
.shop-card--locked .shop-card-media {
  filter: saturate(0.65);
}

.shop-card-btn.is-disabled:hover,
.shop-card-btn.is-disabled:focus-visible {
  transform: none;
  box-shadow: none;
  border-color: var(--border);
}

.shop-card-btn:focus-visible {
  box-shadow: 0 0 0 3px var(--brand-dim), 0 14px 36px rgba(92, 0, 255, 0.16);
}

.shop-card-media {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 20%, rgba(92, 0, 255, 0.18), transparent 55%),
    linear-gradient(180deg, #12121a 0%, #0a0a10 100%);
}

.shop-card--tracks .shop-card-media {
  background:
    radial-gradient(circle at 50% 30%, rgba(139, 92, 246, 0.22), transparent 60%),
    linear-gradient(180deg, #14101c 0%, #0a0a10 100%);
}

.shop-card-vinyl {
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 0 0 8px rgba(255, 255, 255, 0.03),
    inset 0 0 0 16px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(139, 92, 246, 0.15);
  pointer-events: none;
  z-index: 1;
}

.shop-card-vinyl::after {
  content: '';
  position: absolute;
  inset: 42%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.35), rgba(9, 9, 13, 0.9));
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.shop-card-img,
.shop-card-placeholder {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.65rem;
  transition: transform 0.35s var(--ease);
  z-index: 2;
}

.shop-card-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

.shop-card-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.05) 40%, rgba(0, 0, 0, 0.55) 100%);
  pointer-events: none;
  z-index: 2;
}

.shop-card-hover {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  background: rgba(9, 9, 13, 0.72);
  color: var(--brand-light);
  font-size: 0.78rem;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.25s var(--ease);
  z-index: 3;
  pointer-events: none;
}

.shop-card-btn:not(.is-disabled):hover .shop-card-hover,
.shop-card-btn:not(.is-disabled):focus-visible .shop-card-hover {
  opacity: 1;
}

.shop-card-btn:not(.is-disabled):hover .shop-card-img {
  transform: scale(1.04);
}

.shop-card-badge {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  z-index: 2;
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.22rem 0.45rem;
  border-radius: 999px;
  background: rgba(9, 9, 13, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(8px);
}

.shop-card--tracks .shop-card-badge {
  background: rgba(59, 7, 100, 0.55);
  border-color: rgba(139, 92, 246, 0.35);
  color: #ddd6fe;
}

.shop-card-price {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.45rem;
  border-radius: 999px;
  background: rgba(9, 9, 13, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(8px);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--brand-light);
}

.shop-card-price .vbucks { gap: 0.2rem; }

.shop-card-price .vbuck-img {
  width: 13px;
  height: 13px;
}

.shop-card-body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.8rem 0.85rem 0.9rem;
  flex: 1;
  min-height: 0;
}

.shop-card-title {
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shop-card-sub {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shop-card-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  margin-top: auto;
  padding: 0.5rem 0.65rem;
  border-radius: calc(var(--radius-sm) - 2px);
  font-size: 0.72rem;
  font-weight: 700;
  transition: opacity 0.2s, transform 0.2s var(--ease), background 0.2s, color 0.2s, border-color 0.2s;
  border: 1px solid transparent;
}

.shop-card-action--ready {
  color: var(--brand-light);
  background: rgba(92, 0, 255, 0.12);
  border-color: rgba(92, 0, 255, 0.25);
}

.shop-card-action--unlock,
.shop-card-action--no-2fa {
  color: #fcd34d;
  background: rgba(234, 179, 8, 0.1);
  border-color: rgba(234, 179, 8, 0.22);
}

.shop-card-action--no-balance,
.shop-card-action--no-slots,
.shop-card-action--locked,
.shop-card-action--unregistered {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.06);
}

.shop-card-btn:not(.is-disabled):hover .shop-card-action--ready {
  background: rgba(92, 0, 255, 0.2);
  transform: translateY(-1px);
}

.shop-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3.5rem 1.5rem 2.5rem;
  color: var(--muted);
}

.shop-empty-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--muted);
}

.shop-empty-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.35rem;
}

.shop-empty-sub {
  font-size: 0.85rem;
  max-width: 28rem;
  margin: 0 auto;
}

/* ── Skeleton (legacy fallback) ── */
.skeleton-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 1rem;
  min-height: 200px;
}

.skeleton-card {
  aspect-ratio: 0.75;
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--surface-2) 25%, var(--surface-hover) 50%, var(--surface-2) 75%);
  background-size: 200% 100%;
  animation: skeleton 1.2s ease-in-out infinite;
}

@keyframes skeleton {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3.5rem 1.5rem;
  color: var(--muted);
}

.empty-icon { font-size: 2.5rem; margin-bottom: 0.75rem; opacity: 0.6; }

/* ── Recent gifts ── */
.recent-gifts-head {
  align-items: center;
}

.recent-gifts-count {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--brand-light);
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.2);
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  white-space: nowrap;
}

.recent-gifts-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 1rem 1.35rem 1.35rem;
}

.recent-gift-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.85rem;
  padding: 0.95rem 1rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius-sm) + 2px);
  transition: border-color 0.2s, transform 0.2s var(--ease), box-shadow 0.2s;
  animation: recentGiftIn 0.4s var(--ease) both;
}

.recent-gift-item.is-open {
  border-color: rgba(67, 181, 129, 0.28);
  background: linear-gradient(90deg, rgba(67, 181, 129, 0.08), var(--surface-2));
}

@keyframes recentGiftIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: none; }
}

.recent-gift-item:hover {
  border-color: var(--border-hover);
  transform: translateX(4px);
}

.recent-gift-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.2);
  display: grid;
  place-items: center;
  color: var(--brand-light);
  flex-shrink: 0;
}

.recent-gift-body {
  flex: 1;
  min-width: 0;
}

.recent-gift-name {
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.recent-gift-meta {
  margin-top: 0.2rem;
}

.recent-gift-recipient {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.recent-gift-recipient .icon {
  width: 14px;
  height: 14px;
}

.recent-gift-times {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.2rem;
  flex-shrink: 0;
  text-align: right;
}

.recent-gift-ago {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text);
}

.recent-gift-frees,
.recent-gift-status {
  font-size: 0.72rem;
  color: var(--muted);
}

.recent-gift-status.is-open {
  color: var(--success);
  font-weight: 700;
}

.recent-gift-slot {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-top: 0.45rem;
}

.recent-gift-slot-track {
  flex: 1;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.recent-gift-slot-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  transition: width 0.6s var(--ease);
}

.recent-gift-slot-fill.is-open {
  background: linear-gradient(90deg, var(--success), #86efac);
}

.recent-gift-slot-label {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}

.recent-gifts-empty {
  text-align: center;
  padding: 2.25rem 1.5rem 2rem;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.recent-gifts-empty-icon {
  margin: 0 auto 0.75rem;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  display: grid;
  place-items: center;
  color: var(--muted);
}

.recent-gifts-empty p {
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.25rem;
}

.recent-gifts-empty-sub {
  font-size: 0.82rem;
}

#recent-gifts-panel,
.overview-recent {
  margin-bottom: 0;
}

/* ── V-Bucks transfers ── */
#vbucks-panel,
.vbucks-panel {
  margin-bottom: 1.5rem;
  padding: 0;
  overflow: hidden;
}

.vbucks-hero {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 1.35rem 1.35rem 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(135deg, rgba(124, 58, 237, 0.12) 0%, transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
}

.vbucks-hero-glow {
  position: absolute;
  top: -40%;
  right: -10%;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.22), transparent 70%);
  pointer-events: none;
}

.vbucks-hero-main {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  min-width: min(100%, 320px);
  flex: 1 1 320px;
  position: relative;
  z-index: 1;
}

.vbucks-hero-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: #fff;
  background: linear-gradient(145deg, rgba(124, 58, 237, 0.55), rgba(92, 0, 255, 0.35));
  border: 1px solid rgba(167, 139, 250, 0.35);
  box-shadow: 0 8px 24px rgba(92, 0, 255, 0.25);
}

.vbucks-hero-copy .panel-title {
  margin-bottom: 0.35rem;
}

.vbucks-hero-copy .panel-sub {
  max-width: 34rem;
  line-height: 1.5;
}

.vbucks-balance-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  position: relative;
  z-index: 1;
}

.vbucks-balance-card {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 148px;
  padding: 0.85rem 1rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.vbucks-balance-card.is-primary {
  border-color: rgba(124, 58, 237, 0.35);
  background: linear-gradient(180deg, rgba(124, 58, 237, 0.14), rgba(255, 255, 255, 0.03));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.vbucks-balance-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.vbucks-balance-value {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 1.5rem;
  font-size: 1.05rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.vbucks-balance-value .vbucks {
  gap: 0.4rem;
}

.vbucks-balance-range {
  font-family: var(--font-display);
  letter-spacing: -0.02em;
  color: var(--text);
}

.vbucks-compose {
  padding: 1.25rem 1.35rem 1.1rem;
}

.vbucks-send-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.vbucks-compose-row {
  display: grid;
  grid-template-columns: minmax(180px, 220px) 1fr;
  gap: 1rem;
  align-items: start;
}

.vbucks-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.vbucks-field-label {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.52);
}

.vbucks-field-hint {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.38);
  font-weight: 500;
}

.corner-discord-link,
.vbucks-field-hint a {
  color: var(--brand-light);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.corner-discord-link:hover,
.vbucks-field-hint a:hover {
  color: #ddd6fe;
}

.vbucks-input-wrap {
  display: flex;
  align-items: stretch;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.02));
  overflow: hidden;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease), background 0.2s var(--ease);
}

.vbucks-input-wrap:focus-within {
  border-color: rgba(124, 58, 237, 0.55);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.14);
  background: linear-gradient(180deg, rgba(124, 58, 237, 0.08), rgba(255, 255, 255, 0.02));
}

.vbucks-input-wrap-discord .vbucks-input-prefix {
  background: rgba(88, 101, 242, 0.14);
  color: #c7d2fe;
}

.vbucks-input-prefix {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.85rem;
  flex-shrink: 0;
  background: rgba(124, 58, 237, 0.1);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.vbucks-input-prefix img {
  display: block;
  width: 18px;
  height: 18px;
  object-fit: contain;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.18));
}

.vbucks-amount-input,
.vbucks-recipient-input,
.vbucks-input-wrap input {
  flex: 1;
  min-width: 0;
  width: 100%;
  border: none;
  background: transparent;
  padding: 0.78rem 0.9rem;
  color: var(--text);
  font: inherit;
  font-size: 0.94rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.vbucks-amount-input {
  font-weight: 700;
  font-size: 0.98rem;
}

.vbucks-amount-input::placeholder,
.vbucks-recipient-input::placeholder {
  color: rgba(255, 255, 255, 0.28);
  font-weight: 600;
}

.vbucks-amount-input:focus,
.vbucks-recipient-input:focus,
.vbucks-input-wrap input:focus {
  outline: none;
}

.vbucks-quick-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.vbucks-quick-amounts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.vbucks-quick-btn {
  padding: 0.62rem 0.85rem;
  border-radius: calc(var(--radius-sm) + 1px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease), transform 0.15s var(--ease);
}

.vbucks-quick-btn:hover {
  border-color: rgba(124, 58, 237, 0.4);
  background: rgba(124, 58, 237, 0.1);
}

.vbucks-quick-btn:active {
  transform: scale(0.98);
}

.vbucks-send-btn {
  position: relative;
  margin-top: 0.35rem;
  min-height: 56px;
  padding: 0.85rem 1.15rem;
  border-radius: calc(var(--radius-sm) + 4px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    linear-gradient(135deg, #7c3aed 0%, var(--brand) 42%, #5b21b6 100%);
  box-shadow:
    0 10px 28px rgba(92, 0, 255, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.18);
  overflow: hidden;
  isolation: isolate;
}

.vbucks-send-btn::after {
  opacity: 0.35;
}

.vbucks-send-btn:hover {
  transform: translateY(-2px);
  box-shadow:
    0 14px 36px rgba(92, 0, 255, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
}

.vbucks-send-btn:active {
  transform: translateY(0);
}

.vbucks-send-btn-glow {
  position: absolute;
  inset: -30% auto auto 50%;
  width: 220px;
  height: 220px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.22), transparent 68%);
  pointer-events: none;
  z-index: 0;
}

.vbucks-send-btn-inner {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  width: 100%;
}

.vbucks-send-btn-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  flex-shrink: 0;
}

.vbucks-send-btn-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.08rem;
  text-align: left;
}

.vbucks-send-btn-label {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.vbucks-send-btn-sub {
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.72);
  letter-spacing: 0.01em;
}

.vbucks-send-btn:disabled .vbucks-send-btn-sub {
  opacity: 0.7;
}

.vbucks-meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  padding: 0 1.35rem 1.2rem;
}

.vbucks-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.42rem 0.72rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.025);
  font-size: 0.74rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.55);
}

.vbucks-meta-pill .icon {
  color: var(--brand-light);
  opacity: 0.9;
}

.vbucks-field-recipient {
  position: relative;
}

.vbucks-recipient-preview {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-top: 0.15rem;
  padding: 0.65rem 0.8rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  animation: fadeSlideIn 0.3s var(--ease) both;
}

.vbucks-recipient-preview.is-loading {
  opacity: 0.75;
}

.vbucks-recipient-preview.is-error {
  border-color: rgba(237, 66, 69, 0.35);
  background: rgba(237, 66, 69, 0.08);
}

.vbucks-recipient-preview.is-warn {
  border-color: rgba(255, 102, 0, 0.35);
  background: rgba(255, 102, 0, 0.08);
}

.vbucks-recipient-preview.is-ok {
  border-color: rgba(67, 181, 129, 0.35);
  background: rgba(67, 181, 129, 0.08);
}

.vbucks-recipient-status {
  margin-top: 0.15rem;
  padding: 0.55rem 0.7rem;
  border-radius: calc(var(--radius-sm) + 1px);
  font-size: 0.76rem;
  font-weight: 600;
  line-height: 1.45;
  animation: fadeSlideIn 0.25s var(--ease) both;
}

.vbucks-recipient-status.hidden {
  display: none;
}

.vbucks-recipient-status.is-info {
  color: rgba(255, 255, 255, 0.62);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.vbucks-recipient-status.is-ok {
  color: #86efac;
  background: rgba(67, 181, 129, 0.08);
  border: 1px solid rgba(67, 181, 129, 0.28);
}

.vbucks-recipient-status.is-warn {
  color: #fbbf24;
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.28);
}

.vbucks-recipient-status.is-error {
  color: #fca5a5;
  background: rgba(237, 66, 69, 0.08);
  border: 1px solid rgba(237, 66, 69, 0.28);
}

.vbucks-recipient-status .corner-discord-link {
  color: inherit;
  text-decoration: underline;
}

.vbucks-preview-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 2px rgba(92, 0, 255, 0.15);
}

.vbucks-preview-avatar-fallback {
  display: grid;
  place-items: center;
  background: rgba(124, 58, 237, 0.12);
  color: var(--brand-light);
}

.vbucks-preview-copy {
  min-width: 0;
  text-align: left;
}

.vbucks-preview-name {
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.2;
}

.vbucks-preview-sub {
  font-size: 0.76rem;
  color: var(--muted);
  margin-top: 0.1rem;
}

.vbucks-offers-wrap {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  padding: 1.15rem 1.35rem 1.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.12);
}

.vbucks-offers-title {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 0.7rem;
}

.vbucks-offers-title .icon {
  color: var(--brand-light);
}

.vbucks-offers-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.vbucks-offer-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 0.95rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.015));
  animation: fadeSlideIn 0.35s var(--ease) both;
}

.vbucks-offer-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(124, 58, 237, 0.14);
  color: var(--brand-light);
  flex-shrink: 0;
  border: 1px solid rgba(124, 58, 237, 0.2);
}

.vbucks-offer-body {
  flex: 1;
  min-width: 0;
}

.vbucks-offer-amount {
  font-weight: 700;
  font-size: 0.95rem;
}

.vbucks-offer-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.vbucks-offer-meta code {
  font-size: 0.75rem;
}

.vbucks-offer-expiry {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}

.vbucks-offer-expiry.is-urgent {
  color: #f59e0b;
}

.vbucks-offer-actions {
  display: flex;
  gap: 0.4rem;
  flex-shrink: 0;
}

.vbucks-offer-actions .btn-sm {
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
}

@media (max-width: 720px) {
  .vbucks-hero {
    padding: 1.15rem 1.1rem 1rem;
  }

  .vbucks-balance-cards {
    width: 100%;
  }

  .vbucks-balance-card {
    flex: 1 1 calc(50% - 0.35rem);
  }

  .vbucks-compose {
    padding: 1.1rem;
  }

  .vbucks-compose-row {
    grid-template-columns: 1fr;
  }

  .vbucks-meta-row {
    padding: 0 1.1rem 1.1rem;
  }

  .vbucks-offers-wrap {
    padding: 1rem 1.1rem 1.15rem;
  }

  .vbucks-offer-item {
    flex-wrap: wrap;
  }

  .vbucks-offer-actions {
    width: 100%;
    justify-content: flex-end;
  }
}

/* ── V-Bucks confirm modal ── */
.modal-vbucks {
  width: min(500px, calc(100vw - 2rem));
}

.vbucks-confirm-shell.is-sending .vbucks-confirm-actions,
.vbucks-confirm-shell.is-outcome .vbucks-confirm-actions,
.vbucks-confirm-shell.is-success .vbucks-confirm-actions {
  display: none;
}

.vbucks-transfer-visual {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.5rem;
  margin: 1.25rem 0 1rem;
  padding: 1rem 0.5rem;
}

.vbucks-transfer-party {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

.vbucks-transfer-avatar-wrap {
  position: relative;
  width: 72px;
  height: 72px;
}

.vbucks-transfer-avatar-ring {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px solid rgba(92, 0, 255, 0.25);
  animation: vbucksRingPulse 2.4s ease-in-out infinite;
}

.vbucks-transfer-party.is-recipient .vbucks-transfer-avatar-ring {
  animation-delay: 0.4s;
  border-color: rgba(67, 181, 129, 0.35);
}

@keyframes vbucksRingPulse {
  0%, 100% { transform: scale(1); opacity: 0.7; }
  50% { transform: scale(1.06); opacity: 1; }
}

.vbucks-transfer-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  position: relative;
  z-index: 1;
}

.vbucks-transfer-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.vbucks-transfer-name {
  font-size: 0.82rem;
  font-weight: 700;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vbucks-transfer-bridge {
  position: relative;
  width: 96px;
  min-height: 78px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  flex-shrink: 0;
}

.vbucks-bridge-line {
  position: relative;
  width: 100%;
  height: 32px;
}

.vbucks-bridge-beam {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 2px;
  transform: translateY(-50%);
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(92, 0, 255, 0.12) 0%,
    rgba(92, 0, 255, 0.45) 35%,
    rgba(67, 181, 129, 0.55) 65%,
    rgba(67, 181, 129, 0.12) 100%
  );
  overflow: hidden;
}

.vbucks-bridge-beam::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.75), transparent);
  animation: vbucksBeamSweep 1.6s ease-in-out infinite;
}

@keyframes vbucksBeamSweep {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}

.vbucks-bridge-arrow {
  position: absolute;
  top: 50%;
  left: 0;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  color: var(--brand-light);
  filter: drop-shadow(0 0 8px rgba(92, 0, 255, 0.65));
  opacity: 0;
  animation: vbucksArrowFly 1.6s ease-in-out infinite;
}

.vbucks-bridge-arrow .icon {
  width: 16px;
  height: 16px;
}

.vbucks-bridge-arrow-1 { animation-delay: 0s; }
.vbucks-bridge-arrow-2 { animation-delay: 0.28s; }
.vbucks-bridge-arrow-3 { animation-delay: 0.56s; }

@keyframes vbucksArrowFly {
  0% {
    left: 4%;
    opacity: 0;
    transform: translateY(-50%) scale(0.65);
  }
  12% {
    opacity: 1;
    transform: translateY(-50%) scale(1);
  }
  88% {
    opacity: 1;
  }
  100% {
    left: 78%;
    opacity: 0;
    transform: translateY(-50%) scale(0.85);
  }
}

.vbucks-transfer-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.32rem 0.72rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(92, 0, 255, 0.35);
  box-shadow: 0 0 18px rgba(92, 0, 255, 0.22);
  animation: vbucksChipFloat 2.2s ease-in-out infinite;
}

@keyframes vbucksChipFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}

.vbucks-transfer-chip .vbucks-inline,
.vbucks-transfer-chip .vbucks {
  gap: 0.35rem;
}

.vbucks-transfer-avatar-fallback {
  display: grid;
  place-items: center;
  background: var(--brand-dim);
  color: var(--brand-light);
}

.vbucks-confirm-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
  margin-top: 0.5rem;
}

.vbucks-confirm-stat {
  padding: 0.65rem 0.75rem;
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  border: 1px solid var(--border);
  text-align: left;
}

.vbucks-confirm-stat-label {
  display: block;
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 0.2rem;
}

.vbucks-confirm-stat-value {
  display: flex;
  align-items: center;
  font-size: 0.88rem;
  font-weight: 700;
}

.vbucks-confirm-stat-value .vbucks-inline,
.vbucks-confirm-stat-value .vbucks {
  gap: 0.4rem;
}

.vbucks-confirm-note {
  margin-top: 0.85rem;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}

@media (max-width: 640px) {
  .app-tabs {
    gap: 0.25rem;
    padding: 0.35rem;
  }

  .app-tab {
    flex: 1 1 auto;
    justify-content: center;
    padding: 0.55rem 0.65rem;
    font-size: 0.8rem;
  }

  .recent-gift-item {
    flex-wrap: wrap;
  }

  .recent-gift-times {
    flex-direction: row;
    align-items: center;
    width: 100%;
    justify-content: flex-start;
    padding-left: calc(40px + 0.85rem);
  }
}

/* ── Modals ── */
.modal {
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  background: transparent;
  color: var(--text);
  padding: 0;
  width: min(440px, calc(100vw - 2rem));
  max-width: none;
  max-height: calc(100vh - 2rem);
  margin: auto;
  position: fixed;
  inset: 0;
  height: fit-content;
  overflow: visible;
  opacity: 0;
  transform: scale(0.96) translateY(8px);
  transition: opacity 0.28s var(--ease), transform 0.28s var(--ease), overlay 0.28s allow-discrete, display 0.28s allow-discrete;
}

.modal-wide { width: min(520px, calc(100vw - 2rem)); }

.modal-gift {
  width: min(460px, calc(100vw - 2rem));
}

.modal-pipeline {
  width: min(480px, calc(100vw - 2rem));
}

.gift-confirm-shell {
  overflow: hidden;
}

.gift-confirm-inner {
  padding: 1.75rem 1.75rem 1.25rem;
}

.gift-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 0.65rem;
  padding: 1rem 1.75rem 1.5rem;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.2);
}

.gift-confirm-actions .btn {
  width: 100%;
  justify-content: center;
}

/* ── Gift confirm layout ── */
.gift-confirm {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.gift-confirm-header {
  width: 100%;
  margin-bottom: 1.25rem;
}

.gift-confirm-badge {
  width: 52px;
  height: 52px;
  margin: 0 auto 0.85rem;
  border-radius: 14px;
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.25);
  display: grid;
  place-items: center;
  color: var(--brand-light);
  box-shadow: 0 0 24px var(--brand-glow);
}

.gift-confirm-header h3 {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 0.35rem;
}

.gift-confirm-header .modal-lead {
  margin: 0 auto;
  max-width: 28ch;
}

.gift-confirm-card {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.gift-confirm-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.35rem 1.25rem 1.1rem;
  background: linear-gradient(180deg, rgba(92, 0, 255, 0.08), transparent 70%);
  border-bottom: 1px solid var(--border);
}

.gift-preview-img {
  width: 112px;
  height: 112px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  border: 2px solid var(--border);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.gift-preview-img-placeholder {
  width: 112px;
  height: 112px;
  border-radius: var(--radius-sm);
  background: var(--surface-solid);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  border: 2px solid var(--border);
}

.gift-preview-title {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
  margin-top: 0.85rem;
  max-width: 100%;
  padding: 0 0.5rem;
}

.gift-confirm-stats {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0.35rem 0;
}

.gift-stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 1.15rem;
  font-size: 0.85rem;
}

.gift-stat + .gift-stat {
  border-top: 1px solid var(--border);
}

.gift-stat-label {
  color: var(--muted);
  font-weight: 500;
  text-align: left;
}

.gift-stat-value {
  font-weight: 700;
  text-align: right;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.35rem;
  min-width: 0;
}

.gift-stat-value .vbucks {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  white-space: nowrap;
}

.gift-stat-value .vbuck-img {
  width: 14px;
  height: 14px;
  max-width: 14px;
  max-height: 14px;
}

.gift-stat-value .vbuck-amt {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--brand-light);
}

.gift-stat-pill {
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.2);
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.82rem;
}

.gift-stat-muted {
  color: var(--muted);
  font-weight: 600;
}

.balance-picker-wrap {
  width: 100%;
  margin-top: 1.15rem;
  text-align: left;
}

.balance-picker-label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  text-align: center;
}

.balance-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
}

.balance-option {
  padding: 0.85rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-2);
  cursor: pointer;
  text-align: center;
  font: inherit;
  color: var(--text);
  transition: border-color 0.2s, background 0.2s, transform 0.2s var(--ease-bounce);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.balance-option-value .vbucks {
  justify-content: center;
}

.balance-option-value .vbuck-amt {
  color: var(--brand-light);
}

.balance-option:hover { transform: translateY(-2px); border-color: var(--border-hover); }

.balance-option.active {
  border-color: var(--brand);
  background: var(--brand-dim);
  box-shadow: 0 0 0 1px var(--brand);
}

.balance-option-label {
  font-size: 0.72rem;
  color: var(--muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.balance-option-value {
  font-size: 0.9rem;
  font-weight: 700;
}

.balance-option-note {
  margin-top: 0.35rem;
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--muted);
  line-height: 1.35;
  text-transform: none;
  letter-spacing: normal;
}

#gift-preview.is-updating {
  opacity: 0.72;
  pointer-events: none;
  transition: opacity 0.2s var(--ease);
}

.gift-friendship-banner.is-pending,
.borrowed-friendship.is-pending {
  background: rgba(88, 101, 242, 0.08);
  border-color: rgba(88, 101, 242, 0.28);
}

.gift-friendship-banner.is-same-account,
.borrowed-friendship.is-same-account {
  background: rgba(250, 166, 26, 0.08);
  border-color: rgba(250, 166, 26, 0.28);
}

.gift-friendship-banner.is-pending .gift-friendship-icon,
.borrowed-friendship.is-pending {
  color: var(--brand);
}

.gift-friendship-banner.is-same-account .gift-friendship-icon,
.borrowed-friendship.is-same-account {
  color: var(--warn);
}

.gift-friendship-banner {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  margin-top: 1rem;
  padding: 0.85rem 0.95rem;
  border-radius: var(--radius-sm);
  text-align: left;
}

.gift-friendship-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(255, 102, 0, 0.12);
  color: var(--warning);
  flex-shrink: 0;
}

.gift-friendship-title {
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.gift-friendship-body,
.gift-friendship-foot {
  font-size: 0.84rem;
  color: var(--muted);
  line-height: 1.45;
}

.gift-friendship-foot {
  margin-top: 0.35rem;
}

.gift-friend-request-btn {
  margin-top: 0.65rem;
}

.friendship-account-badge {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin: 0.35rem 0 0.5rem;
  padding: 0.4rem 0.55rem;
  border-radius: 999px;
  background: rgba(124, 58, 237, 0.1);
  border: 1px solid rgba(124, 58, 237, 0.22);
}

.friendship-account-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.friendship-account-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.12rem 0.45rem;
  border-radius: 6px;
}

.friendship-wait-timer {
  margin-top: 0.65rem;
  padding: 0.65rem 0.75rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.friendship-wait-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.45rem;
}

.friendship-wait-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.friendship-wait-value {
  font-size: 0.92rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--brand-light);
}

.friendship-wait-track {
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.friendship-wait-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  transition: width 0.35s var(--ease);
}

.friendship-wait-timer.is-urgent .friendship-wait-value {
  color: var(--warning);
}

.friendship-wait-timer.is-urgent .friendship-wait-fill {
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.friendship-wait-timer.is-ready .friendship-wait-value {
  color: var(--success);
}

.gift-stat-account {
  font-size: 0.82rem;
  word-break: break-word;
}

.gift-stat-hint {
  display: block;
  margin-top: 0.3rem;
  font-size: 0.76rem;
  font-weight: 500;
  color: var(--muted);
  line-height: 1.4;
}

#borrowed-lender-panel {
  margin-bottom: 1.5rem;
}

.borrowed-lender-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem;
}

.borrowed-lender-stat {
  padding: 0.75rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.borrowed-lender-stat-wide {
  grid-column: 1 / -1;
}

.borrowed-lender-stat-label {
  display: block;
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 0.2rem;
}

.borrowed-lender-stat-value {
  font-weight: 700;
  font-size: 0.92rem;
}

.borrowed-lender-stat-hint {
  display: block;
  margin-top: 0.35rem;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}

.borrowed-lender-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.85rem;
}

#lent-loans-panel {
  margin-bottom: 1.5rem;
}

.lent-loans-count {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--muted);
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
}

.lent-loans-body {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.lent-loan-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.8rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}

.lent-loan-name {
  font-weight: 700;
  font-size: 0.92rem;
}

.lent-loan-sub {
  margin-top: 0.15rem;
  font-size: 0.78rem;
  color: var(--muted);
}

.borrowed-friendship {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin-top: 0.85rem;
  padding: 0.8rem 0.9rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.borrowed-friendship-ok {
  background: rgba(67, 181, 129, 0.08);
  border-color: rgba(67, 181, 129, 0.25);
  color: var(--text);
  font-size: 0.84rem;
}

.borrowed-friendship-warn {
  background: rgba(255, 102, 0, 0.08);
  border-color: rgba(255, 102, 0, 0.25);
}

.borrowed-friendship-title {
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.borrowed-friendship-body,
.borrowed-friendship-foot {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.45;
}

#btn-borrowed-friend-request {
  margin-top: 0.75rem;
}

@media (max-width: 420px) {
  .gift-confirm-actions {
    grid-template-columns: 1fr;
  }

  .gift-confirm-inner {
    padding: 1.35rem 1.15rem 1rem;
  }
}

.modal-shell {
  display: flex;
  flex-direction: column;
  background: var(--surface-solid);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
  overflow: hidden;
  max-height: calc(100vh - 2rem);
}

.modal[open] {
  opacity: 1;
  transform: scale(1) translateY(0);
}

.modal::backdrop {
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.3s var(--ease), overlay 0.3s allow-discrete, display 0.3s allow-discrete;
}

.modal[open]::backdrop { opacity: 1; }

@starting-style {
  .modal[open] { opacity: 0; transform: scale(0.96) translateY(8px); }
  .modal[open]::backdrop { opacity: 0; }
}

.modal-inner {
  padding: 1.75rem;
  overflow-y: auto;
  flex: 1;
}

.modal-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  margin-bottom: 1rem;
  color: var(--brand-light);
}

.modal-icon .icon { width: 26px; height: 26px; }

.modal h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.modal p {
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 1.25rem;
  line-height: 1.55;
}

.modal-actions {
  display: flex;
  gap: 0.75rem;
  padding: 1rem 1.75rem 1.75rem;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.15);
}

.modal-actions-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.modal-actions-split .btn { width: 100%; justify-content: center; }

.btn-block { width: 100%; justify-content: center; }

#form-2fa .auth-actions { padding-left: 0; padding-right: 0; padding-bottom: 0; border-top: none; background: none; margin-top: 0.5rem; }

/* ── OTP inputs ── */
.otp-inputs {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 0.5rem;
}

.otp-digit {
  width: 44px;
  height: 52px;
  text-align: center;
  font-size: 1.35rem;
  font-weight: 700;
  font-family: monospace;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.15s var(--ease-bounce);
}

.otp-digit:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-dim);
  transform: scale(1.05);
}

/* ── Gift receipt (success modal) ── */
.modal-icon-lock { background: var(--brand-dim); }

.modal-lead {
  margin: 0 0 1rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.mono {
  font-family: ui-monospace, monospace;
  font-size: 0.85rem;
}

.gift-detail-rows { display: flex; flex-direction: column; gap: 0.35rem; }

.gift-detail-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--border);
}

.gift-detail-row:last-child { border-bottom: none; }

.gift-detail-row span:first-child { color: var(--muted); }

.gift-detail-row span:last-child {
  text-align: right;
  max-width: 58%;
}

.gift-detail-row .vbucks {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.3rem;
}

.gift-detail-row .vbuck-img {
  width: 14px;
  height: 14px;
  max-width: 14px;
  max-height: 14px;
}

.gift-detail-row .vbuck-amt {
  color: var(--brand-light);
}

/* ── Success receipt ── */
.success-header {
  text-align: center;
  margin-bottom: 1.25rem;
}

.success-check {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--success-dim);
  border: 2px solid var(--success);
  display: grid;
  place-items: center;
  font-size: 1.75rem;
  margin: 0 auto 1rem;
  animation: successPop 0.5s var(--ease-bounce) both;
}

@keyframes successPop {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.receipt-card {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1rem;
}

/* ── Toast stack ── */
.toast-stack {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column-reverse;
  gap: 0.6rem;
  z-index: 300;
  width: min(420px, calc(100vw - 2rem));
  align-items: stretch;
}

.toast-item {
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius-sm);
  background: var(--surface-solid);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  font-size: 0.88rem;
  font-weight: 500;
  animation: toastIn 0.35s var(--ease-bounce) both;
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  width: 100%;
}

.toast-body {
  flex: 1;
  min-width: 0;
}

.toast-title {
  font-weight: 700;
  font-size: 0.92rem;
  line-height: 1.3;
  margin-bottom: 0.25rem;
}

.toast-message {
  font-size: 0.84rem;
  font-weight: 400;
  color: var(--muted);
  line-height: 1.45;
}

.toast-message-only {
  flex: 1;
  min-width: 0;
}

.toast-message p {
  margin: 0 0 0.35rem;
}

.toast-message p:last-child {
  margin-bottom: 0;
}

.toast-message strong {
  color: var(--text);
  font-weight: 600;
}

.toast-message code {
  background: rgba(0, 0, 0, 0.25);
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  font-size: 0.9em;
}

.toast-footer {
  font-size: 0.76rem;
  color: var(--muted);
  margin-top: 0.4rem;
  opacity: 0.9;
  line-height: 1.4;
}

.toast-icon {
  flex-shrink: 0;
  margin-top: 0.1rem;
}

.toast-item.success {
  border-color: rgba(67, 181, 129, 0.45);
  background: linear-gradient(135deg, var(--surface-solid), rgba(67, 181, 129, 0.06));
}

.toast-item.success .toast-title { color: var(--success); }
.toast-item.success .toast-icon { color: var(--success); }

.toast-item.error {
  border-color: rgba(237, 66, 69, 0.45);
  background: linear-gradient(135deg, var(--surface-solid), rgba(237, 66, 69, 0.06));
}

.toast-item.error .toast-title { color: #ff9a9c; }
.toast-item.error .toast-icon { color: var(--error); }

.toast-item.warn {
  border-color: rgba(255, 102, 0, 0.4);
  background: linear-gradient(135deg, var(--surface-solid), rgba(255, 102, 0, 0.06));
}

.toast-item.warn .toast-title { color: #ffb366; }
.toast-item.warn .toast-icon { color: var(--warning); }

.toast-item.info .toast-icon { color: var(--brand-light); }

@keyframes toastIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

.toast-item.toast-out { animation: toastOut 0.25s var(--ease) forwards; }

@keyframes toastOut {
  to { opacity: 0; transform: translateY(8px); }
}


/* ── Loading spinner ── */
.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.2);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Settings panel ── */
.settings-panel {
  padding: 0;
  overflow: hidden;
}

.settings-panel.is-loading .settings-card {
  pointer-events: none;
}

.settings-panel.is-loading .settings-link-form,
.settings-panel.is-loading .settings-link-pipeline,
.settings-panel.is-loading .settings-link-outcome {
  display: none !important;
}

.settings-skeleton-block,
.settings-profile-row--skeleton .settings-profile-avatar,
.settings-epic-badge--skeleton,
.settings-security-item--skeleton {
  background: linear-gradient(90deg, var(--surface-2) 20%, var(--surface-hover) 50%, var(--surface-2) 80%);
  background-size: 200% 100%;
  animation: skeleton 1.3s ease-in-out infinite;
  border-color: transparent !important;
}

.settings-profile-row--skeleton .settings-profile-avatar {
  border: none;
}

.settings-epic-badge--skeleton {
  min-height: 4.5rem;
}

.settings-security-item--skeleton {
  animation: skeletonStatIn 0.45s var(--ease) both;
  animation-delay: calc(var(--skeleton-i) * 0.06s + 0.08s);
}

.settings-hero {
  position: relative;
  overflow: hidden;
  padding: 1.35rem 1.35rem 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background:
    linear-gradient(135deg, rgba(124, 58, 237, 0.14) 0%, transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
}

.settings-hero-glow {
  position: absolute;
  top: -50%;
  right: -10%;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.22), transparent 70%);
  pointer-events: none;
}

.settings-hero-orbit {
  position: absolute;
  border-radius: 50%;
  border: 1px dashed rgba(167, 139, 250, 0.15);
  pointer-events: none;
}

.settings-hero-orbit--1 {
  width: 220px;
  height: 220px;
  top: -60px;
  left: -40px;
  animation: settingsOrbitSpin 18s linear infinite;
}

.settings-hero-orbit--2 {
  width: 160px;
  height: 160px;
  top: 10px;
  right: 12%;
  animation: settingsOrbitSpin 24s linear infinite reverse;
}

@keyframes settingsOrbitSpin {
  to { transform: rotate(360deg); }
}

.settings-hero-main {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  position: relative;
  z-index: 1;
}

.settings-hero-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(145deg, rgba(124, 58, 237, 0.55), rgba(92, 0, 255, 0.35));
  border: 1px solid rgba(167, 139, 250, 0.35);
  box-shadow: 0 8px 24px rgba(92, 0, 255, 0.25);
  animation: settingsIconFloat 4s ease-in-out infinite;
}

@keyframes settingsIconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
  padding: 1.15rem 1.35rem 1.35rem;
}

.settings-card {
  position: relative;
  padding: 1.1rem 1.15rem;
  border-radius: calc(var(--radius) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.01));
  overflow: hidden;
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.25s var(--ease);
}

.settings-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: linear-gradient(180deg, var(--brand-light), transparent);
  opacity: 0.65;
}

.settings-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22);
}

.settings-card--epic {
  grid-column: 1 / -1;
}

.settings-card--epic::before {
  background: linear-gradient(180deg, #60a5fa, transparent);
}

.settings-card--epic.is-success {
  border-color: rgba(67, 181, 129, 0.35);
  box-shadow: 0 0 0 1px rgba(67, 181, 129, 0.12), 0 16px 40px rgba(67, 181, 129, 0.08);
  animation: settingsSuccessPulse 0.8s var(--ease);
}

.settings-card--epic.is-error {
  border-color: rgba(237, 66, 69, 0.35);
}

@keyframes settingsSuccessPulse {
  0% { box-shadow: 0 0 0 0 rgba(67, 181, 129, 0.35); }
  100% { box-shadow: 0 0 0 1px rgba(67, 181, 129, 0.12), 0 16px 40px rgba(67, 181, 129, 0.08); }
}

.settings-card-head {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.settings-card-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--brand-light);
  background: var(--brand-dim);
  border: 1px solid rgba(92, 0, 255, 0.2);
}

.settings-card--discord .settings-card-icon {
  color: #fff;
  background: rgba(88, 101, 242, 0.18);
  border-color: rgba(88, 101, 242, 0.28);
}

.settings-card-title {
  margin: 0 0 0.2rem;
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.settings-card-sub {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.45;
}

.settings-profile-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.settings-profile-avatar,
.settings-profile-avatar-fallback {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  object-fit: cover;
  flex-shrink: 0;
}

.settings-profile-avatar-fallback {
  display: grid;
  place-items: center;
  background: rgba(88, 101, 242, 0.15);
  border: 1px solid rgba(88, 101, 242, 0.25);
}

.settings-profile-name {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
}

.settings-profile-meta {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.76rem;
  color: var(--muted);
}

.settings-epic-badge {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(96, 165, 250, 0.22);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(255, 255, 255, 0.02));
}

.settings-epic-badge--empty {
  border-color: rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
}

.settings-epic-badge-label {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.settings-epic-badge-value {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.settings-link-form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.settings-field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.settings-field-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.settings-input-wrap {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.65rem 0.85rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.settings-input-wrap:focus-within {
  border-color: rgba(96, 165, 250, 0.45);
  background: rgba(59, 130, 246, 0.06);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.settings-input-prefix {
  color: var(--muted);
  flex-shrink: 0;
}

.settings-input-wrap input {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  outline: none;
  min-width: 0;
}

.settings-field-hint {
  font-size: 0.74rem;
  color: var(--muted);
  line-height: 1.4;
}

.settings-link-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.settings-link-pipeline {
  position: relative;
  margin-top: 1rem;
  padding: 1rem;
  border-radius: calc(var(--radius-sm) + 2px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  overflow: hidden;
  animation: settingsPipelineIn 0.35s var(--ease) both;
}

@keyframes settingsPipelineIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.settings-pipeline-glow {
  position: absolute;
  inset: -30% auto auto 20%;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(92, 0, 255, 0.16), transparent 70%);
  pointer-events: none;
}

.settings-pipeline-track {
  margin-bottom: 0.85rem;
}

.settings-link-outcome {
  margin-top: 0.85rem;
  animation: settingsPipelineIn 0.35s var(--ease) both;
}

.settings-outcome {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
}

.settings-outcome-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.settings-outcome--success .settings-outcome-icon {
  color: var(--success);
  background: rgba(67, 181, 129, 0.12);
  border: 1px solid rgba(67, 181, 129, 0.25);
}

.settings-outcome--error .settings-outcome-icon {
  color: var(--error);
  background: rgba(237, 66, 69, 0.12);
  border: 1px solid rgba(237, 66, 69, 0.25);
}

.settings-outcome-title {
  font-size: 0.92rem;
  font-weight: 800;
}

.settings-outcome-body {
  margin-top: 0.15rem;
  font-size: 0.84rem;
  color: var(--text);
}

.settings-outcome-footer {
  margin-top: 0.35rem;
  font-size: 0.76rem;
  color: var(--muted);
}

.settings-outcome-retry {
  margin-top: 0.65rem;
}

.settings-security-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.settings-security-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  border-radius: calc(var(--radius-sm) - 2px);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.settings-security-label {
  font-size: 0.78rem;
  color: var(--muted);
}

.settings-security-value {
  font-size: 0.78rem;
  font-weight: 700;
}

.settings-security-foot {
  margin: 0.35rem 0 0;
  font-size: 0.74rem;
  color: var(--muted);
  line-height: 1.45;
}

.settings-signout {
  width: 100%;
  justify-content: center;
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .landing-tilt-card {
    transform: none !important;
  }
}

@media (max-width: 640px) {
  .landing-title { font-size: 1.75rem; }
  .page-intro { flex-direction: column; align-items: flex-start; }
  .search-wrap { max-width: none; width: 100%; }
  .toast-stack { left: 1rem; right: 1rem; max-width: none; }

  .overview-hero {
    grid-template-columns: 1fr;
    grid-template-areas:
      "main"
      "cards"
      "actions";
    padding: 1rem;
  }

  .overview-hero-cards {
    width: 100%;
  }

  .overview-hero-card {
    flex: 1 1 calc(50% - 0.35rem);
    min-width: 0;
  }

  .overview-hero-actions {
    width: 100%;
  }

  .overview-hero-actions .btn {
    flex: 1 1 calc(50% - 0.3rem);
    justify-content: center;
  }

  .overview-metrics {
    grid-template-columns: 1fr;
  }

  .overview-recent-head {
    flex-direction: column;
    padding: 1rem 1rem 0.75rem;
  }

  .recent-gifts-list {
    padding: 0.85rem 1rem 1rem;
  }

  .recent-gift-item {
    grid-template-columns: auto 1fr;
    grid-template-areas:
      "icon body"
      "times times";
  }

  .recent-gift-icon { grid-area: icon; }
  .recent-gift-body { grid-area: body; }
  .recent-gift-times {
    grid-area: times;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    text-align: left;
    padding-top: 0.35rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
  }

  .session-panel-body {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .session-panel-countdown {
    min-width: 0;
    width: 100%;
  }

  .session-panel-action {
    width: 100%;
  }

  .shop-hero {
    padding: 1rem;
    flex-direction: column;
  }

  .shop-hero-cards {
    width: 100%;
  }

  .shop-hero-card {
    flex: 1 1 calc(50% - 0.35rem);
    min-width: 0;
  }

  .shop-controls {
    margin: 0 0.65rem;
    padding: 0.75rem 0.75rem 0;
    top: 0.5rem;
  }

  .shop-controls-top {
    flex-direction: column;
    align-items: stretch;
  }

  .shop-search { width: 100%; max-width: none; }

  .shop-controls-actions {
    justify-content: space-between;
    width: 100%;
  }

  .shop-toolbar { flex-direction: column; align-items: stretch; }
  .shop-filters-row { flex-direction: column; align-items: stretch; }
  .shop-filters { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 0.15rem; scrollbar-width: none; }
  .shop-filters::-webkit-scrollbar { display: none; }
  .shop-price-chips { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 0.15rem; scrollbar-width: none; }
  .shop-price-chips::-webkit-scrollbar { display: none; }
  .shop-price-filter { align-self: flex-start; flex-shrink: 0; }
  .shop-sort { justify-content: space-between; }
  .shop-reset { align-self: flex-start; }

  .shop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    padding: 0.85rem 1rem 1rem;
  }

  .shop-grid--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .shop-card-title { font-size: 0.8rem; }

  .header-user-copy { display: none; }
  .header-user-trigger { padding-right: 0.45rem; }

  .settings-grid {
    grid-template-columns: 1fr;
  }
}
