/* ════════════════════════════════════════════════════════════
   VOYIRA AI — Main CSS v4 Enhanced
   Luxury · Smooth · Modern · Animated
════════════════════════════════════════════════════════════ */

/* ── TOKENS ─────────────────────────────────────────────── */
:root {
  --bg:        #04050d;
  --bg2:       #080b18;
  --bg3:       #0d1022;
  --surface:   #10142a;
  --surface2:  #161b35;
  --surface3:  #1c2340;
  --border:    rgba(255,255,255,0.05);
  --border2:   rgba(255,255,255,0.09);
  --border3:   rgba(129,140,248,0.2);
  --text:      #eceef8;
  --text2:     #8e94c0;
  --muted:     #4e5580;
  --pulse:     #818cf8;
  --pulse2:    #06b6d4;
  --green:     #34d399;
  --amber:     #f59e0b;
  --red:       #f43f5e;
  --grad:      linear-gradient(135deg, #818cf8, #06b6d4, #34d399);
  --gradsoft:  linear-gradient(135deg, rgba(129,140,248,.1), rgba(6,182,212,.1));
  --gradglow:  linear-gradient(135deg, rgba(129,140,248,.2), rgba(6,182,212,.15));
  --r-sm:      8px;
  --r-md:      13px;
  --r-lg:      18px;
  --r-xl:      24px;
  --r-2xl:     32px;
  --shadow:    0 8px 40px rgba(0,0,0,.6);
  --shadow-sm: 0 2px 14px rgba(0,0,0,.35);
  --shadow-glow: 0 0 40px rgba(129,140,248,.12);
  --topbar-h:  60px;
  --nav-h:     66px;
  --sidebar-w: 265px;
  --ease:      cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease2:     cubic-bezier(0.4, 0, 0.2, 1);
  --ease3:     cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── RESET ───────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
  height: 100dvh;
  -webkit-font-smoothing: antialiased;
}
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, textarea, select {
  font-family: inherit; color: var(--text);
  background: var(--surface); border: 1.5px solid var(--border2);
  border-radius: var(--r-md); padding: 11px 15px; width: 100%;
  transition: border-color .25s, box-shadow .25s, background .25s; outline: none; font-size: .9rem;
}
input:focus, textarea:focus, select:focus {
  border-color: var(--pulse);
  background: var(--surface2);
  box-shadow: 0 0 0 4px rgba(129,140,248,.12), 0 2px 12px rgba(0,0,0,.3);
}
select option { background: var(--surface2); }
a { color: var(--pulse); text-decoration: none; transition: color .2s; }
a:hover { text-decoration: underline; }
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--surface3); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--muted); }

/* ── NOISE TEXTURE ───────────────────────────────────────── */
body::after {
  content: '';
  position: fixed; inset: 0; z-index: 1;
  pointer-events: none; opacity: .018;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 200px 200px;
}

/* ── STAR CANVAS ─────────────────────────────────────────── */
#starCanvas {
  position: fixed; inset: 0; z-index: 0;
  pointer-events: none; opacity: .65;
}

/* ── AMBIENT ORBS ────────────────────────────────────────── */
.orb {
  position: fixed; border-radius: 50%;
  filter: blur(100px); pointer-events: none; z-index: 0;
  will-change: transform;
}
.orb-a {
  width: 520px; height: 520px;
  background: radial-gradient(circle, rgba(129,140,248,.11), transparent 70%);
  top: -160px; left: -160px;
  animation: orbDriftA 20s ease-in-out infinite alternate;
}
.orb-b {
  width: 460px; height: 460px;
  background: radial-gradient(circle, rgba(6,182,212,.08), transparent 70%);
  bottom: -120px; right: -120px;
  animation: orbDriftB 25s ease-in-out infinite alternate;
}
.orb-c {
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(52,211,153,.06), transparent 70%);
  top: 35%; left: 35%;
  animation: orbDriftC 30s ease-in-out infinite alternate;
}

@keyframes orbDriftA {
  0%   { transform: translate(0,0) scale(1); }
  50%  { transform: translate(50px,35px) scale(1.07); }
  100% { transform: translate(25px,65px) scale(.96); }
}
@keyframes orbDriftB {
  0%   { transform: translate(0,0) scale(1); }
  50%  { transform: translate(-60px,-40px) scale(1.09); }
  100% { transform: translate(-25px,45px) scale(.94); }
}
@keyframes orbDriftC {
  0%   { transform: translate(0,0) scale(1) rotate(0deg); }
  100% { transform: translate(-35px,-50px) scale(1.14) rotate(8deg); }
}

/* ════════════════════════════════════════════════════════════
   AUTH
════════════════════════════════════════════════════════════ */
.auth-overlay {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center;
  background: rgba(4,5,13,.88);
  backdrop-filter: blur(20px) saturate(1.4);
  padding: 16px;
  opacity: 0; pointer-events: none;
  transition: opacity .5s var(--ease2);
}
.auth-overlay.active { opacity: 1; pointer-events: all; }

/* Grid dots pattern */
.auth-overlay::before {
  content: '';
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(129,140,248,.09) 1px, transparent 1px);
  background-size: 36px 36px;
  pointer-events: none;
}

.auth-card {
  background: linear-gradient(160deg, var(--surface2) 0%, var(--surface) 60%, rgba(13,16,34,.95) 100%);
  border: 1px solid rgba(129,140,248,.18);
  border-radius: var(--r-2xl);
  padding: 36px 32px;
  width: 100%; max-width: 430px;
  box-shadow: var(--shadow), var(--shadow-glow),
              inset 0 1px 0 rgba(255,255,255,.05),
              inset 0 -1px 0 rgba(0,0,0,.3);
  animation: cardIn .6s var(--ease3) both;
  position: relative; z-index: 1;
  max-height: 90dvh; overflow-y: auto;
}

/* Top luminous edge */
.auth-card::before {
  content: '';
  position: absolute; top: 0; left: 15%; right: 15%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(129,140,248,.7), rgba(6,182,212,.5), transparent);
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(40px) scale(.94); }
  to   { opacity: 1; transform: none; }
}

.auth-logo {
  display: flex; align-items: center; gap: 14px; margin-bottom: 32px;
}
.logo-icon { position: relative; }
.logo-icon svg { display: block; filter: drop-shadow(0 0 14px rgba(129,140,248,.45)); }
.logo-icon::after {
  content: '';
  position: absolute; inset: -6px;
  background: radial-gradient(circle, rgba(129,140,248,.18), transparent 70%);
  border-radius: 50%;
  animation: logoGlow 3.5s ease-in-out infinite;
}
@keyframes logoGlow {
  0%,100% { opacity: .5; transform: scale(1); }
  50%      { opacity: 1; transform: scale(1.2); }
}
.logo-name { font-size: 1.5rem; font-weight: 800; letter-spacing: -.04em; }
.logo-name em {
  background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  font-style: normal; background-size: 200%;
  animation: gradShift 5s linear infinite;
}
.logo-domains { font-size: .62rem; color: var(--muted); letter-spacing: .14em; margin-top: 2px; }

.auth-form { display: none; }
.auth-form.active { display: block; animation: formIn .4s var(--ease3) both; }
@keyframes formIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

.auth-form h2 { font-size: 1.45rem; font-weight: 800; margin-bottom: 5px; letter-spacing: -.03em; }
.auth-sub { color: var(--text2); font-size: .85rem; margin-bottom: 22px; }

.field { margin-bottom: 15px; }
.field label {
  display: block; font-size: .73rem; font-weight: 700; color: var(--text2);
  margin-bottom: 7px; letter-spacing: .05em; text-transform: uppercase;
}
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 44px; }
.pw-toggle {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; font-size: 1rem; opacity: .5;
  transition: opacity .2s;
}
.pw-toggle:hover { opacity: 1; }

.btn-auth {
  width: 100%; padding: 14px; border-radius: var(--r-md);
  background: var(--grad); color: #fff; font-weight: 700; font-size: .95rem;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: transform .25s var(--ease), box-shadow .25s; margin-top: 10px;
  background-size: 200%; animation: gradShift 5s linear infinite;
  letter-spacing: .02em; position: relative; overflow: hidden;
}
.btn-auth::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.1), transparent 55%);
  pointer-events: none;
}
.btn-auth:hover { transform: translateY(-3px); box-shadow: 0 14px 40px rgba(129,140,248,.5), 0 4px 16px rgba(6,182,212,.2); }
.btn-auth:active { transform: translateY(-1px); }
.btn-auth:disabled { opacity: .5; transform: none; cursor: not-allowed; animation: none; background: var(--surface2); }

@keyframes gradShift {
  0%,100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

.auth-or {
  display: flex; align-items: center; gap: 12px;
  color: var(--muted); font-size: .78rem; margin: 16px 0; letter-spacing: .06em;
}
.auth-or::before, .auth-or::after { content: ''; flex: 1; height: 1px; background: var(--border2); }

.btn-ghost {
  width: 100%; padding: 12px; border-radius: var(--r-md);
  border: 1.5px solid var(--border2); color: var(--text2); font-size: .88rem;
  font-weight: 600; transition: all .25s var(--ease2);
}
.btn-ghost:hover {
  border-color: var(--border3); color: var(--text);
  background: rgba(129,140,248,.07);
  box-shadow: 0 0 0 4px rgba(129,140,248,.05);
}

.auth-switch { font-size: .82rem; color: var(--muted); text-align: center; margin-top: 18px; }
.auth-switch a { color: var(--pulse); font-weight: 700; }

.auth-err {
  background: rgba(244,63,94,.1); border: 1px solid rgba(244,63,94,.25);
  border-radius: var(--r-sm); padding: 10px 14px; font-size: .82rem; color: #fb7185;
  margin-bottom: 12px;
  animation: errShake .35s var(--ease2);
}
@keyframes errShake {
  0%,100% { transform: translateX(0); }
  20%,60% { transform: translateX(-5px); }
  40%,80% { transform: translateX(5px); }
}

.avatar-upload {
  width: 84px; height: 84px; border-radius: 50%; cursor: pointer;
  border: 2px dashed var(--border2); margin: 0 auto 18px;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; transition: all .25s var(--ease2);
  background: var(--surface2);
}
.avatar-upload:hover { border-color: var(--pulse); background: rgba(129,140,248,.08); transform: scale(1.05); }
.avatar-ph { text-align: center; font-size: .7rem; color: var(--muted); }
.avatar-ph span { display: block; font-size: 1.6rem; margin-bottom: 3px; }

.reg-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.reg-grid .field { margin-bottom: 0; }
.reg-grid .field.full { grid-column: 1 / -1; }

/* ════════════════════════════════════════════════════════════
   APP SHELL
════════════════════════════════════════════════════════════ */
.app {
  position: fixed; inset: 0; z-index: 10;
  display: flex; flex-direction: column;
  opacity: 0; pointer-events: none;
  transition: opacity .5s var(--ease3);
}
.app:not(.hidden) { opacity: 1; pointer-events: all; }
.hidden { display: none !important; }

/* ── TOPBAR ──────────────────────────────────────────────── */
.topbar {
  height: var(--topbar-h); min-height: var(--topbar-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 14px;
  background: rgba(4,5,13,.8);
  backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid var(--border);
  position: relative; z-index: 50; flex-shrink: 0;
  box-shadow: 0 1px 0 rgba(255,255,255,.03), 0 4px 24px rgba(0,0,0,.35);
}
.topbar::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(129,140,248,.5) 30%, rgba(6,182,212,.35) 65%, transparent 100%);
}

.topbar-l { display: flex; align-items: center; gap: 12px; }

.menu-btn {
  width: 36px; height: 36px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 5px;
  border-radius: var(--r-sm); transition: background .2s;
}
.menu-btn:hover { background: var(--surface2); }
.bar {
  display: block; width: 18px; height: 1.5px; border-radius: 2px;
  background: var(--text2); transition: all .3s var(--ease3);
}

.topbar-brand { display: flex; align-items: center; gap: 10px; }
.topbar-brand svg { filter: drop-shadow(0 0 8px rgba(129,140,248,.3)); }
.brand-name { font-size: 1.1rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.brand-name em {
  background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  font-style: normal; background-size: 200%; animation: gradShift 5s linear infinite;
}
.brand-domains { font-size: .58rem; color: var(--muted); letter-spacing: .12em; line-height: 1; }

.topbar-nav { display: flex; align-items: center; gap: 4px; }
.nav-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 7px 14px; border-radius: var(--r-md);
  color: var(--muted); font-size: .8rem; font-weight: 600;
  transition: all .25s var(--ease2); position: relative;
}
.nav-btn:hover { color: var(--text2); background: var(--surface); }
.nav-btn.active { color: var(--pulse); background: rgba(129,140,248,.1); }
.nav-btn.active::after {
  content: '';
  position: absolute; bottom: -1px; left: 20%; right: 20%; height: 2px;
  background: var(--grad); border-radius: 2px 2px 0 0;
  animation: slideIn .3s var(--ease3);
}
@keyframes slideIn { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.nav-ico { width: 16px; height: 16px; flex-shrink: 0; transition: transform .2s var(--ease); }
.nav-btn:hover .nav-ico { transform: scale(1.12); }

.topbar-r { display: flex; align-items: center; gap: 8px; }

.chip-info {
  display: flex; align-items: center; gap: 7px; padding: 5px 12px;
  border-radius: 99px; background: var(--surface); border: 1px solid var(--border);
  font-size: .72rem; color: var(--text2); font-weight: 600;
}
.chip-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--green);
  box-shadow: 0 0 8px rgba(52,211,153,.7);
  animation: dotPulse 2s ease-in-out infinite;
}
@keyframes dotPulse {
  0%,100% { box-shadow: 0 0 6px rgba(52,211,153,.6); }
  50%      { box-shadow: 0 0 14px rgba(52,211,153,.95); }
}

.user-chip {
  display: flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px;
  border-radius: 99px; background: var(--surface); border: 1px solid var(--border2);
  font-size: .78rem; font-weight: 700; cursor: pointer; transition: all .25s var(--ease2);
}
.user-chip:hover { border-color: var(--border3); background: var(--surface2); box-shadow: var(--shadow-glow); }
.uc-av {
  width: 26px; height: 26px; border-radius: 50%; overflow: hidden;
  background: var(--grad); display: flex; align-items: center; justify-content: center;
  font-size: .75rem; color: #fff; font-weight: 800; flex-shrink: 0;
}

/* ── LAYOUT ──────────────────────────────────────────────── */
.layout {
  flex: 1; display: flex; overflow: hidden;
  height: calc(100dvh - var(--topbar-h));
}

/* ── SIDEBAR ─────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w); min-width: var(--sidebar-w);
  display: flex; flex-direction: column;
  background: rgba(6,8,18,.85);
  backdrop-filter: blur(20px);
  border-right: 1px solid var(--border);
  transition: transform .35s var(--ease3);
  z-index: 40; overflow: hidden;
}
.sb-head { padding: 16px 14px 12px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.sb-new {
  width: 100%; padding: 10px 14px; border-radius: var(--r-md);
  background: var(--gradsoft); border: 1px solid var(--border3);
  color: var(--pulse); font-size: .84rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: all .25s var(--ease);
}
.sb-new:hover {
  background: var(--gradglow); border-color: var(--pulse);
  box-shadow: 0 0 24px rgba(129,140,248,.2); transform: translateY(-1px);
}
.sb-new svg { transition: transform .3s var(--ease); }
.sb-new:hover svg { transform: rotate(90deg); }

.sb-list { flex: 1; overflow-y: auto; padding: 10px; }

.sb-item {
  display: flex; align-items: center; gap: 9px; padding: 9px 10px;
  border-radius: var(--r-sm); cursor: pointer; margin-bottom: 2px;
  transition: all .2s var(--ease2); position: relative;
  color: var(--text2); font-size: .82rem; font-weight: 500;
}
.sb-item:hover { background: var(--surface); color: var(--text); }
.sb-item.active {
  background: rgba(129,140,248,.1); color: var(--pulse);
  border: 1px solid rgba(129,140,248,.15);
}
.sb-item.active::before {
  content: '';
  position: absolute; left: 0; top: 18%; bottom: 18%; width: 3px;
  background: var(--grad); border-radius: 0 2px 2px 0;
}
.sb-title { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-del {
  opacity: 0; padding: 3px; border-radius: 4px; color: var(--muted);
  transition: all .15s; font-size: .75rem;
}
.sb-item:hover .sb-del { opacity: 1; }
.sb-del:hover { background: rgba(244,63,94,.15); color: var(--red); }

.sb-section {
  padding: 16px 14px 8px; font-size: .63rem; font-weight: 800;
  color: var(--muted); letter-spacing: .12em; text-transform: uppercase; flex-shrink: 0;
}
.sb-footer { padding: 12px 10px; border-top: 1px solid var(--border); flex-shrink: 0; }
.sb-logout {
  width: 100%; padding: 9px 14px; border-radius: var(--r-sm);
  display: flex; align-items: center; gap: 9px; color: var(--muted);
  font-size: .82rem; font-weight: 600; transition: all .2s;
}
.sb-logout:hover { color: var(--red); background: rgba(244,63,94,.08); }

.sb-backdrop {
  display: none; position: fixed; inset: 0; z-index: 35;
  background: rgba(0,0,0,.55); backdrop-filter: blur(4px);
  opacity: 0; transition: opacity .3s;
}
.sb-backdrop.vis { opacity: 1; }

/* ── MAIN ────────────────────────────────────────────────── */
.main { flex: 1; overflow: hidden; display: flex; flex-direction: column; position: relative; }

.tab {
  display: none; flex: 1; flex-direction: column;
  height: 100%; overflow: hidden;
  animation: tabIn .35s var(--ease3) both;
}
.tab.active { display: flex; }
@keyframes tabIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}

/* ── LIMIT BANNER ────────────────────────────────────────── */
.limit-banner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 18px;
  background: linear-gradient(135deg, rgba(245,158,11,.08), rgba(251,191,36,.04));
  border-bottom: 1px solid rgba(245,158,11,.2);
  font-size: .8rem; color: var(--amber); flex-shrink: 0;
}
.limit-banner button {
  padding: 4px 14px; border-radius: 99px;
  background: rgba(245,158,11,.14); color: var(--amber);
  font-size: .73rem; font-weight: 800; transition: all .2s;
  border: 1px solid rgba(245,158,11,.2);
}
.limit-banner button:hover { background: rgba(245,158,11,.28); }

/* ── BOTTOM NAV MOBILE ───────────────────────────────────── */
.bottom-nav {
  display: none;
  height: var(--nav-h); min-height: var(--nav-h);
  background: rgba(4,5,13,.92);
  backdrop-filter: blur(24px) saturate(1.5);
  border-top: 1px solid var(--border);
  padding: 0 10px; padding-bottom: env(safe-area-inset-bottom);
  position: relative; z-index: 50; flex-shrink: 0;
  box-shadow: 0 -1px 0 rgba(255,255,255,.03), 0 -4px 24px rgba(0,0,0,.3);
}
.bnav-btn {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 8px 4px;
  color: var(--muted); font-size: .62rem; font-weight: 700;
  transition: all .25s var(--ease3); border-radius: var(--r-md);
  letter-spacing: .03em; position: relative;
}
.bnav-btn:hover { color: var(--text2); background: rgba(255,255,255,.03); }
.bnav-btn.active { color: var(--pulse); }
.bnav-btn.active svg { stroke: var(--pulse); }
.bnav-btn.active::before {
  content: '';
  position: absolute; top: -1px; left: 25%; right: 25%; height: 2px;
  background: var(--grad); border-radius: 0 0 2px 2px;
  animation: slideIn .3s var(--ease3);
}
.bnav-btn svg { transition: transform .25s var(--ease); }
.bnav-btn:hover svg { transform: translateY(-2px) scale(1.08); }

.bnav-btn.scan-center {
  background: linear-gradient(160deg, rgba(129,140,248,.12), rgba(6,182,212,.09));
  border: 1px solid rgba(129,140,248,.18);
  border-radius: var(--r-lg);
  position: relative; top: -8px;
  height: 56px; flex: 1.25;
  box-shadow: 0 4px 18px rgba(129,140,248,.14), inset 0 1px 0 rgba(255,255,255,.05);
}
.bnav-btn.scan-center.active {
  background: linear-gradient(160deg, rgba(129,140,248,.24), rgba(6,182,212,.18));
  border-color: var(--pulse);
  box-shadow: 0 0 22px rgba(129,140,248,.32), inset 0 1px 0 rgba(255,255,255,.08);
}

/* ── CHAT ────────────────────────────────────────────────── */
#tabChat { justify-content: space-between; }
.chat-wrap { flex: 1; overflow-y: auto; padding: 20px 16px; }

/* Welcome */
.welcome {
  display: flex; flex-direction: column; align-items: center;
  padding: 52px 20px 28px; text-align: center;
  animation: welcomeIn .7s var(--ease3) both;
}
@keyframes welcomeIn {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}

.ai-orb { position: relative; width: 120px; height: 120px; margin-bottom: 28px; }
.ring {
  position: absolute; border-radius: 50%; border: 1px solid;
  animation: ringPulse 3.5s ease-in-out infinite;
}
.r1 { inset: 0; border-color: rgba(129,140,248,.4); animation-delay: 0s; }
.r2 { inset: -14px; border-color: rgba(6,182,212,.22); animation-delay: .6s; }
.r3 { inset: -28px; border-color: rgba(52,211,153,.12); animation-delay: 1.2s; }
@keyframes ringPulse {
  0%,100% { opacity: .4; transform: scale(1); }
  50%      { opacity: 1; transform: scale(1.03); }
}
.ai-core-center {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 35% 35%, var(--surface3), var(--surface));
  border-radius: 50%;
  box-shadow: inset 0 2px 4px rgba(255,255,255,.05), 0 4px 20px rgba(0,0,0,.4), 0 0 30px rgba(129,140,248,.1);
}

.wc-title { font-size: 1.8rem; font-weight: 800; margin-bottom: 10px; letter-spacing: -.04em; line-height: 1.2; }
.wc-title span {
  background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-size: 200%; animation: gradShift 5s linear infinite;
}
.wc-sub { color: var(--text2); font-size: .88rem; margin-bottom: 22px; max-width: 360px; line-height: 1.65; }

.wc-badges { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-bottom: 28px; }
.badge {
  padding: 5px 15px; border-radius: 99px; font-size: .72rem; font-weight: 700;
  transition: all .2s var(--ease);
}
.badge:hover { transform: translateY(-2px); filter: brightness(1.2); }
.badge.edu { background: rgba(129,140,248,.12); color: var(--pulse); border: 1px solid rgba(129,140,248,.22); }
.badge.med { background: rgba(52,211,153,.12); color: var(--green); border: 1px solid rgba(52,211,153,.22); }
.badge.tech { background: rgba(6,182,212,.12); color: var(--pulse2); border: 1px solid rgba(6,182,212,.22); }

.quick-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; max-width: 500px; width: 100%; }
.qchip {
  padding: 12px 10px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--border2);
  color: var(--text2); font-size: .78rem; font-weight: 600;
  transition: all .25s var(--ease);
  position: relative; overflow: hidden;
  animation: chipIn .5s var(--ease3) both;
}
.qchip::before {
  content: ''; position: absolute; inset: 0;
  background: var(--gradsoft); opacity: 0; transition: opacity .25s;
}
.qchip:hover { color: var(--text); border-color: var(--border3); transform: translateY(-3px); box-shadow: 0 8px 24px rgba(129,140,248,.12); }
.qchip:hover::before { opacity: 1; }
@keyframes chipIn {
  from { opacity: 0; transform: translateY(10px) scale(.96); }
  to   { opacity: 1; transform: none; }
}
.qchip:nth-child(1){animation-delay:.1s}
.qchip:nth-child(2){animation-delay:.15s}
.qchip:nth-child(3){animation-delay:.2s}
.qchip:nth-child(4){animation-delay:.25s}
.qchip:nth-child(5){animation-delay:.3s}
.qchip:nth-child(6){animation-delay:.35s}

/* Messages */
.msgs { display: flex; flex-direction: column; gap: 18px; padding-bottom: 10px; }
.msg {
  display: flex; align-items: flex-end; gap: 10px;
  opacity: 0; transform: translateY(14px);
  transition: opacity .35s var(--ease3), transform .35s var(--ease3);
}
.msg.in { opacity: 1; transform: none; }
.msg.user { flex-direction: row-reverse; }

.msg-av {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: .75rem; font-weight: 800; overflow: hidden;
  transition: transform .2s var(--ease);
}
.msg:hover .msg-av { transform: scale(1.08); }
.ai-av { background: var(--surface2); border: 1px solid var(--border2); box-shadow: 0 0 10px rgba(129,140,248,.15); }
.user-av { background: var(--grad); box-shadow: 0 0 10px rgba(129,140,248,.25); }

.msg-body { max-width: 78%; }
.msg-bubble {
  padding: 13px 17px; border-radius: var(--r-lg);
  font-size: .875rem; line-height: 1.65; word-break: break-word;
  transition: box-shadow .2s;
}
.msg-bubble:hover { box-shadow: 0 4px 18px rgba(0,0,0,.25); }
.assistant .msg-bubble {
  background: var(--surface); border: 1px solid var(--border);
  border-bottom-left-radius: 4px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.03);
}
.user .msg-bubble {
  background: linear-gradient(135deg, #4338ca, #0e7490);
  color: #fff; border-bottom-right-radius: 4px;
  box-shadow: 0 4px 22px rgba(67,56,202,.3), inset 0 1px 0 rgba(255,255,255,.12);
}

.md-h2 { font-size: 1.05rem; font-weight: 800; margin: 10px 0 5px; color: var(--pulse); }
.md-h3 { font-size: .92rem; font-weight: 700; margin: 7px 0 3px; }
.inline-code {
  font-family: 'JetBrains Mono', monospace; font-size: .78em;
  background: var(--surface2); padding: 2px 7px; border-radius: 5px; color: var(--pulse2);
  border: 1px solid var(--border);
}
blockquote {
  border-left: 3px solid var(--pulse); padding: 6px 12px; color: var(--text2);
  margin: 6px 0; background: rgba(129,140,248,.04); border-radius: 0 4px 4px 0;
}
li { margin-left: 18px; margin-bottom: 3px; }

/* Typing indicator */
.typing-row { display: flex; align-items: center; gap: 10px; padding: 10px 18px; flex-shrink: 0; }
.typing-dots { display: flex; gap: 5px; }
.typing-dots span {
  width: 7px; height: 7px; border-radius: 50%; background: var(--pulse);
  animation: typingBounce 1.3s ease-in-out infinite;
}
.typing-dots span:nth-child(2) { animation-delay: .18s; background: var(--pulse2); }
.typing-dots span:nth-child(3) { animation-delay: .36s; background: var(--green); }
@keyframes typingBounce {
  0%,60%,100% { transform: translateY(0) scale(1); }
  30%          { transform: translateY(-7px) scale(1.12); }
}
.typing-label { font-size: .76rem; color: var(--muted); font-style: italic; }

/* Input Dock */
.input-dock { padding: 10px 14px 14px; flex-shrink: 0; position: relative; }
.input-dock::before {
  content: '';
  position: absolute; top: -40px; left: 0; right: 0; height: 40px;
  background: linear-gradient(180deg, transparent, rgba(4,5,13,.7));
  pointer-events: none;
}
.input-box {
  display: flex; align-items: flex-end; gap: 8px;
  background: var(--surface); border: 1.5px solid var(--border2);
  border-radius: var(--r-xl); padding: 8px 8px 8px 16px;
  transition: border-color .25s, box-shadow .25s, background .25s;
  box-shadow: 0 2px 14px rgba(0,0,0,.25);
}
.input-box:focus-within {
  border-color: var(--pulse); background: var(--surface2);
  box-shadow: 0 0 0 4px rgba(129,140,248,.1), 0 4px 22px rgba(129,140,248,.12);
}
#chatIn {
  flex: 1; background: none; border: none; box-shadow: none; padding: 6px 0;
  resize: none; font-size: .88rem; line-height: 1.55; max-height: 160px;
  overflow-y: auto; color: var(--text);
}
#chatIn::placeholder { color: var(--muted); }
.inp-tools { display: flex; gap: 4px; align-items: flex-end; flex-shrink: 0; }
.itool {
  width: 34px; height: 34px; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); transition: all .2s var(--ease2);
}
.itool:hover { background: var(--surface2); color: var(--text); transform: scale(1.1); }
.send-btn {
  width: 40px; height: 40px; border-radius: var(--r-md);
  background: var(--grad); display: flex; align-items: center; justify-content: center;
  transition: transform .25s var(--ease), opacity .2s, box-shadow .25s;
  background-size: 200%; animation: gradShift 5s linear infinite;
  box-shadow: 0 4px 16px rgba(129,140,248,.32);
  position: relative; overflow: hidden;
}
.send-btn::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.12), transparent 50%);
  pointer-events: none;
}
.send-btn:hover { transform: scale(1.1) translateY(-1px); box-shadow: 0 8px 28px rgba(129,140,248,.55); }
.send-btn:active { transform: scale(.95); }
.send-btn:disabled { opacity: .4; transform: none; cursor: not-allowed; animation: none; background: var(--surface2); box-shadow: none; }
.send-btn svg { stroke: #fff; }
.inp-note { font-size: .67rem; color: var(--muted); text-align: center; margin-top: 7px; opacity: .65; }

/* Fade Up util */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

/* r4 ring extra */
.r4 { inset: -44px; border-color: rgba(129,140,248,.06); animation-delay: 1.8s; }

/* chip-info layout fix */
.chip-info { display: flex; flex-direction: column; gap: 1px; }
.chip-plan { font-size: .62rem; color: var(--muted); }

/* uc-av fallback */
.uc-av { background: var(--grad); }

/* sidebar elements that kept old class names */
.sb-top { padding: 16px 14px 12px; border-bottom: 1px solid var(--border); flex-shrink: 0; }
.new-chat-btn {
  width: 100%; padding: 10px 14px; border-radius: var(--r-md);
  background: var(--gradsoft); border: 1px solid var(--border3);
  color: var(--pulse); font-size: .84rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  transition: all .25s var(--ease);
}
.new-chat-btn:hover {
  background: var(--gradglow); border-color: var(--pulse);
  box-shadow: 0 0 24px rgba(129,140,248,.18); transform: translateY(-1px);
}
.new-chat-btn svg { transition: transform .3s var(--ease); }
.new-chat-btn:hover svg { transform: rotate(90deg); }

.sb-hist { flex: 1; overflow-y: auto; padding: 10px; }

.sb-bottom { padding: 12px 10px; border-top: 1px solid var(--border); flex-shrink: 0; }
.sb-user {
  display: flex; align-items: center; gap: 9px; padding: 9px 10px;
  border-radius: var(--r-sm); margin-bottom: 4px;
}
.sb-av {
  width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
  background: var(--grad);
  display: flex; align-items: center; justify-content: center;
  font-size: .76rem; font-weight: 800; color: #fff; overflow: hidden;
}
.sb-uinfo { display: flex; flex-direction: column; gap: 1px; overflow: hidden; }
.sb-uinfo span { font-size: .82rem; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-email { font-size: .72rem !important; font-weight: 500 !important; color: var(--muted); }

.logout-btn {
  width: 100%; padding: 9px 14px; border-radius: var(--r-sm);
  display: flex; align-items: center; gap: 9px; color: var(--muted);
  font-size: .82rem; font-weight: 600; transition: all .2s;
}
.logout-btn:hover { color: var(--red); background: rgba(244,63,94,.08); }

/* topbar chip-av */
.chip-av {
  width: 26px; height: 26px; border-radius: 50%; overflow: hidden;
  background: var(--grad); display: flex; align-items: center; justify-content: center;
  font-size: .75rem; color: #fff; font-weight: 800; flex-shrink: 0;
}

/* ════════════════════════════════════════════════════════════
   MARKDOWN RENDERING — missing styles
════════════════════════════════════════════════════════════ */
.md-h4 { font-size:.85rem; font-weight:700; margin:6px 0 2px; color:var(--text2); }

.code-block {
  background: #0a0d1a;
  border: 1px solid var(--border2);
  border-radius: var(--r-md);
  padding: 14px 16px;
  margin: 10px 0;
  overflow-x: auto;
  font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  font-size: .8rem;
  line-height: 1.65;
  color: #a5b4fc;
  position: relative;
}
.code-block::before {
  content: 'CODE';
  position: absolute; top: 6px; right: 10px;
  font-size: .6rem; color: var(--muted); letter-spacing: .1em;
  font-family: sans-serif;
}
.code-block code { background: none; border: none; padding: 0; color: inherit; font-size: inherit; }

.msg-bubble ul, .msg-bubble ol {
  margin: 8px 0 8px 20px;
  display: flex; flex-direction: column; gap: 4px;
}
.msg-bubble li {
  margin: 0;
  line-height: 1.55;
  color: inherit;
}
.msg-bubble ul li::marker { color: var(--pulse); }
.msg-bubble ol li::marker { color: var(--pulse2); font-weight: 700; }

.md-hr {
  border: none;
  border-top: 1px solid var(--border2);
  margin: 12px 0;
}

/* Fix: user bubble markdown shouldn't use surface colors */
.user .msg-bubble .inline-code {
  background: rgba(255,255,255,.15);
  border-color: rgba(255,255,255,.2);
  color: #fff;
}
.user .msg-bubble blockquote {
  border-left-color: rgba(255,255,255,.5);
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.85);
}

/* ── Typing indicator better positioning ──────────────── */
.typing-row {
  padding: 8px 18px 4px;
}

/* ── Sidebar history items — fix active state ─────────── */
.hist-item {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 10px; border-radius: var(--r-sm);
  cursor: pointer; margin-bottom: 2px;
  transition: all .2s var(--ease2);
  color: var(--text2); font-size: .82rem; font-weight: 500;
  white-space: nowrap; overflow: hidden;
}
.hist-item span { overflow: hidden; text-overflow: ellipsis; }
.hist-item:hover { background: var(--surface); color: var(--text); }
.hist-item.active {
  background: rgba(129,140,248,.1);
  color: var(--pulse);
  border: 1px solid rgba(129,140,248,.15);
}

.sb-empty {
  text-align: center; color: var(--muted);
  font-size: .8rem; padding: 24px 12px;
  line-height: 1.6;
}

/* ── Limit banner upgrade button ──────────────────────── */
.limit-banner a {
  color: var(--amber); font-weight: 800;
  font-size: .73rem; text-decoration: none;
}

/* ── Welcome screen responsive fix ───────────────────── */
@media (max-width: 420px) {
  .quick-grid { grid-template-columns: repeat(2,1fr); }
  .wc-title { font-size: 1.45rem; }
}

/* ── Loading shimmer for AI response ─────────────────── */
.msg-loading .msg-bubble {
  background: linear-gradient(90deg,
    var(--surface) 25%, var(--surface2) 50%, var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
  min-width: 120px; min-height: 36px;
  color: transparent;
}
@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── Scan meta items ─────────────────────────────────── */
.scan-meta-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
}
.sm-ico { font-size: 1.4rem; flex-shrink: 0; }
.sm-info { display: flex; flex-direction: column; gap: 2px; }
.sm-lbl { font-size: .7rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.sm-val { font-size: .9rem; font-weight: 700; }

/* ════════════════════════════════════════════════════════════
   SIDEBAR COLLAPSE ANIMATION
════════════════════════════════════════════════════════════ */
.sidebar {
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1), 
              transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar.collapsed {
  width: 0;
  min-width: 0;
  overflow: hidden;
  opacity: 0;
}

.main {
  transition: margin-left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.main.sidebar-collapsed {
  margin-left: 0;
}

/* ── SIDEBAR TOGGLE BUTTON ───────────────────────────────── */
.sidebar-toggle {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text2);
  cursor: pointer;
  transition: all 0.3s var(--ease);
}

.sidebar-toggle:hover {
  background: var(--surface2);
  border-color: var(--border3);
  color: var(--pulse);
  transform: scale(1.05);
}

.sidebar-toggle svg {
  transition: transform 0.3s var(--ease);
}

.sidebar.collapsed .sidebar-toggle svg {
  transform: rotate(180deg);
}

/* ════════════════════════════════════════════════════════════
   TYPING EFFECT ANIMATION
════════════════════════════════════════════════════════════ */
.typing-cursor {
  display: inline-block;
  width: 2px;
  height: 1.2em;
  background-color: var(--pulse);
  margin-left: 2px;
  animation: blink 0.8s step-end infinite;
  vertical-align: middle;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.msg.typing-animation .msg-bubble {
  background: var(--surface);
  min-width: 80px;
}

.msg.user.typing-animation .msg-bubble {
  background: linear-gradient(135deg, #4338ca, #0e7490);
}

.msg-bubble.typed {
  animation: fadeInUp 0.3s var(--ease3) both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── THINKING INDICATOR ─────────────────────────────────── */
.thinking-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 0;
}

.thinking-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--pulse);
  animation: thinkingPulse 1.4s ease-in-out infinite;
}

.thinking-dot:nth-child(2) {
  animation-delay: 0.2s;
  background: var(--pulse2);
}

.thinking-dot:nth-child(3) {
  animation-delay: 0.4s;
  background: var(--green);
}

@keyframes thinkingPulse {
  0%, 60%, 100% {
    transform: translateY(0);
    opacity: 0.4;
  }
  30% {
    transform: translateY(-6px);
    opacity: 1;
  }
}

/* ── MESSAGE SMOOTH ENTRY ───────────────────────────────── */
.msg {
  animation: slideInMessage 0.4s var(--ease3) forwards;
}

@keyframes slideInMessage {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── MODAL ENHANCEMENT ──────────────────────────────────── */
.modal-box {
  animation: modalSlideIn 0.4s var(--ease3) both;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: scale(0.95) translateY(-20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* ── SIDEBAR HISTORY ITEMS ANIMATION ────────────────────── */
.hist-item {
  transition: all 0.25s var(--ease2);
  animation: slideInLeft 0.3s var(--ease3) both;
  animation-delay: calc(var(--i, 0) * 0.03s);
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* ── DESKTOP SIDEBAR TOGGLE ─────────────────────────────── */
@media (min-width: 1025px) {
  .sidebar {
    position: relative;
    transform: none !important;
  }
  
  .sidebar.collapsed {
    width: 0;
    min-width: 0;
  }
  
  .sb-backdrop {
    display: none !important;
  }
}

/* ── MOBILE SIDEBAR ─────────────────────────────────────── */
@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: var(--topbar-h);
    bottom: 0;
    width: min(280px, 80vw);
    transform: translateX(-100%);
    transition: transform 0.3s var(--ease3);
  }
  
  .sidebar.open {
    transform: translateX(0);
  }
  
  .sidebar.collapsed {
    width: min(280px, 80vw);
    transform: translateX(-100%);
  }
  
  .sb-backdrop {
    display: block;
  }
  
  .main.sidebar-collapsed {
    margin-left: 0;
  }
}
/* ═══════════════════════════════════════════════════════════
   VOYIRA AI — Additional & Override CSS v6
   Mobile Fix · Animated Logo · Store Orders · Clean UI
═══════════════════════════════════════════════════════════ */

/* ── ANIMATED LOGO ──────────────────────────────────────── */
.animated-logo {
  position: relative;
  width: 64px; height: 64px;
  display: flex; align-items: center; justify-content: center;
}
.logo-ring {
  position: absolute; border-radius: 50%;
  border: 1.5px solid transparent;
  animation: logoRingSpin linear infinite;
}
.logo-ring.r1 {
  inset: 0;
  border-top-color: #818cf8;
  border-right-color: rgba(129,140,248,.3);
  animation-duration: 3s;
}
.logo-ring.r2 {
  inset: -8px;
  border-top-color: #06b6d4;
  border-left-color: rgba(6,182,212,.3);
  animation-duration: 4.5s;
  animation-direction: reverse;
}
.logo-ring.r3 {
  inset: -16px;
  border-bottom-color: #34d399;
  border-right-color: rgba(52,211,153,.25);
  animation-duration: 7s;
}
@keyframes logoRingSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.logo-core {
  position: relative; z-index: 2;
  filter: drop-shadow(0 0 12px rgba(129,140,248,.6));
  animation: logoCoreGlow 3s ease-in-out infinite;
}
@keyframes logoCoreGlow {
  0%,100% { filter: drop-shadow(0 0 12px rgba(129,140,248,.5)); }
  50%      { filter: drop-shadow(0 0 22px rgba(6,182,212,.8)); }
}

/* ── TOPBAR BRAND LOGO ANIMATED ─────────────────────────── */
.brand-logo-anim {
  position: relative; width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
}
.blr1, .blr2 {
  position: absolute; border-radius: 50%; border: 1px solid transparent;
  animation: logoRingSpin linear infinite;
}
.blr1 {
  inset: 0; border-top-color: rgba(129,140,248,.7);
  animation-duration: 3s;
}
.blr2 {
  inset: -4px; border-top-color: rgba(6,182,212,.5);
  animation-duration: 5s; animation-direction: reverse;
}
.brand-logo-anim svg {
  position: relative; z-index: 2;
  filter: drop-shadow(0 0 7px rgba(129,140,248,.45));
}

/* ── AI AVATAR ANIMATED ─────────────────────────────────── */
.ai-av-inner {
  display: flex; align-items: center; justify-content: center;
}
.ai-av {
  background: var(--surface2) !important;
  border: 1.5px solid rgba(129,140,248,.25) !important;
  box-shadow: 0 0 12px rgba(129,140,248,.2),
              inset 0 0 8px rgba(129,140,248,.05) !important;
  animation: aiAvGlow 4s ease-in-out infinite;
}
@keyframes aiAvGlow {
  0%,100% { box-shadow: 0 0 10px rgba(129,140,248,.2); }
  50%      { box-shadow: 0 0 20px rgba(6,182,212,.35); }
}

/* ── THINKING DOTS FIX ──────────────────────────────────── */
.thinking-dot {
  display: inline-block;
  width: 7px; height: 7px; border-radius: 50%;
  margin: 0 2px;
  animation: thinkingPulse 1.4s ease-in-out infinite;
}
.thinking-dot:nth-child(1) { background: #818cf8; animation-delay: 0s; }
.thinking-dot:nth-child(2) { background: #06b6d4; animation-delay: .2s; }
.thinking-dot:nth-child(3) { background: #34d399; animation-delay: .4s; }

/* ═══════════════════════════════════════════════════════════
   MOBILE OVERRIDES — Full Fix
═══════════════════════════════════════════════════════════ */
@media (max-width: 768px) {

  /* App must fill entire screen */
  body { overflow: hidden; height: 100dvh; }
  .app { position: fixed; inset: 0; display: flex; flex-direction: column; }

  /* Topbar: compact, no nav tabs */
  .topbar { padding: 0 10px; gap: 8px; }
  .topbar-nav { display: none !important; }
  .brand-domains { display: none; }
  .brand-name { font-size: 1rem; }
  .chip-info span:not(.chip-plan) { font-size: .75rem; }
  .chip-plan { font-size: .6rem; }

  /* Layout: no sidebar pushing content */
  .layout {
    flex: 1; overflow: hidden;
    height: calc(100dvh - var(--topbar-h) - var(--nav-h));
    position: relative;
  }

  /* Sidebar: drawer overlay */
  .sidebar {
    position: fixed !important;
    top: var(--topbar-h); left: 0;
    bottom: var(--nav-h);
    width: min(285px, 82vw) !important;
    min-width: 0 !important;
    transform: translateX(-100%) !important;
    transition: transform .3s var(--ease3), box-shadow .3s !important;
    z-index: 200;
    box-shadow: none;
  }
  .sidebar.open {
    transform: translateX(0) !important;
    box-shadow: 4px 0 40px rgba(0,0,0,.7) !important;
  }
  .sb-backdrop {
    display: block !important;
    position: fixed; inset: 0; z-index: 190;
    background: rgba(0,0,0,.65);
    backdrop-filter: blur(4px);
    pointer-events: none; opacity: 0;
    transition: opacity .3s;
  }
  .sb-backdrop.vis { opacity: 1; pointer-events: all; }

  /* Main: full width */
  .main { width: 100%; margin-left: 0 !important; }

  /* Bottom nav: always shown on mobile */
  .bottom-nav {
    display: flex !important;
    position: fixed !important;
    bottom: 0; left: 0; right: 0;
    height: var(--nav-h);
    padding-bottom: env(safe-area-inset-bottom, 0);
    z-index: 100;
    align-items: center;
  }

  /* Chat: adjust for bottom nav */
  #tabChat {
    display: flex; flex-direction: column;
    height: calc(100dvh - var(--topbar-h) - var(--nav-h));
    overflow: hidden;
  }
  .chat-wrap {
    flex: 1; overflow-y: auto;
    padding: 14px 12px 6px;
    -webkit-overflow-scrolling: touch;
  }
  .input-dock { padding: 6px 10px 8px; }
  .input-box { border-radius: 18px; padding: 6px 6px 6px 13px; }
  #chatIn { font-size: .84rem; }
  .inp-note { display: none; }
  .send-btn { width: 36px; height: 36px; }

  /* Welcome screen: compact */
  .welcome { padding: 24px 14px 16px; }
  .ai-orb { width: 90px; height: 90px; margin-bottom: 18px; }
  .r2 { inset: -10px; }
  .r3 { inset: -20px; }
  .r4 { inset: -30px; }
  .wc-title { font-size: 1.35rem; }
  .wc-sub { font-size: .82rem; margin-bottom: 16px; }
  .wc-badges { gap: 6px; margin-bottom: 18px; }
  .badge { font-size: .68rem; padding: 4px 11px; }
  .quick-grid { grid-template-columns: repeat(2,1fr); gap: 8px; max-width: 100%; }
  .qchip { padding: 10px 8px; font-size: .75rem; }

  /* Messages */
  .msgs { gap: 12px; }
  .msg-body { max-width: 88%; }
  .msg-bubble { font-size: .84rem; padding: 10px 14px; }
  .msg-av { width: 28px; height: 28px; font-size: .68rem; }

  /* Tabs: fill full available height */
  .tab { height: calc(100dvh - var(--topbar-h) - var(--nav-h)); }
  .tab.active { display: flex; flex-direction: column; }

  /* Limit banner */
  .limit-banner { font-size: .73rem; padding: 7px 12px; }

  /* Store */
  .store-wrap { padding: 16px 12px 80px; overflow-y: auto; height: 100%; }
  .store-hero { margin-bottom: 16px; }
  .store-hero h2 { font-size: 1.25rem; }
  .product-grid { grid-template-columns: 1fr 1fr !important; gap: 10px !important; }
  .prod-card { border-radius: 14px !important; }
  .prod-ico { font-size: 1.8rem !important; }
  .prod-name { font-size: .82rem !important; }
  .prod-desc { font-size: .72rem !important; }
  .prod-price { font-size: .9rem !important; }
  .btn-order { font-size: .75rem !important; padding: 8px 10px !important; }
  .filter-bar { gap: 6px !important; padding: 0 0 12px !important; overflow-x: auto; flex-wrap: nowrap !important; }
  .fpill { font-size: .72rem !important; padding: 6px 12px !important; white-space: nowrap; flex-shrink: 0; }

  /* Scan */
  .scan-wrap { padding: 16px 12px 80px; overflow-y: auto; height: 100%; }
  .scan-hdr h2 { font-size: 1.2rem; }
  .cam-frame { max-height: 55vw !important; }

  /* Profile */
  .profile-wrap { padding: 16px 12px 80px; overflow-y: auto; height: 100%; }
  .prof-banner { gap: 14px; padding: 18px 14px !important; }
  .stats-row { grid-template-columns: repeat(4,1fr) !important; gap: 8px !important; }
  .sv { font-size: 1.3rem !important; }
  .plans-grid { grid-template-columns: 1fr 1fr !important; }

  /* Auth card: better mobile fit */
  .auth-card { padding: 24px 20px; border-radius: 20px; }
  .auth-logo { margin-bottom: 20px; }
  .animated-logo { width: 50px; height: 50px; }
  .logo-name { font-size: 1.3rem; }
  .reg-grid { grid-template-columns: 1fr; }
  .reg-grid .field.full { grid-column: 1; }

  /* Modals */
  .modal-box { max-height: 92dvh !important; margin: 0 8px !important; }

  /* Topbar r-side */
  .topbar-r .user-chip { padding: 4px 9px 4px 4px; }
  .chip-info { gap: 1px; }
}

/* ═══════════════════════════════════════════════════════════
   STORE — Order Modal Channels
═══════════════════════════════════════════════════════════ */
.store-order-info {
  font-size: .8rem; color: var(--text2); margin-top: 6px;
}
.order-prod-preview {
  display: flex; align-items: center; gap: 14px;
  padding: 14px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--border2);
  margin-bottom: 16px;
}
.order-prod-emoji { font-size: 2.4rem; flex-shrink: 0; }
.order-prod-name  { font-weight: 700; font-size: .95rem; margin-bottom: 3px; }
.order-prod-desc  { font-size: .78rem; color: var(--muted); }
.order-prod-price { font-size: .88rem; color: var(--pulse); font-weight: 700; margin-top: 4px; }

.order-channel-label {
  font-size: .75rem; font-weight: 700; color: var(--text2);
  text-transform: uppercase; letter-spacing: .06em;
  margin: 16px 0 10px;
}
.order-channels {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px;
}
.btn-wa, .btn-email {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px; border-radius: var(--r-md);
  font-size: .85rem; font-weight: 700;
  transition: transform .2s var(--ease), box-shadow .2s;
  border: 1.5px solid transparent;
}
.btn-wa {
  background: linear-gradient(135deg, #25d366, #128c7e);
  color: #fff;
  box-shadow: 0 4px 18px rgba(37,211,102,.25);
}
.btn-wa:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(37,211,102,.4); }
.btn-email {
  background: var(--surface); border-color: var(--border2);
  color: var(--text2);
}
.btn-email:hover {
  border-color: var(--pulse); color: var(--pulse);
  background: rgba(129,140,248,.08);
  transform: translateY(-2px);
}

/* ── PRODUCT CARD IMPROVEMENTS ──────────────────────────── */
.product-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px; padding: 4px 2px;
}
.prod-card {
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: var(--r-lg); overflow: hidden;
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
  display: flex; flex-direction: column;
  cursor: default;
}
.prod-card:hover {
  transform: translateY(-4px); border-color: var(--border3);
  box-shadow: 0 12px 36px rgba(129,140,248,.12);
}
.prod-ico {
  font-size: 2.5rem; text-align: center; padding: 20px 0 10px;
  background: linear-gradient(180deg, var(--surface2), transparent);
}
.prod-body { padding: 14px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.prod-name { font-weight: 700; font-size: .9rem; line-height: 1.3; }
.prod-desc { font-size: .78rem; color: var(--muted); line-height: 1.45; flex: 1; }
.prod-price { font-size: 1rem; font-weight: 800; color: var(--pulse); }
.prod-stock { font-size: .72rem; color: var(--text2); }
.btn-order {
  width: 100%; padding: 10px; border-radius: var(--r-sm);
  background: var(--gradsoft); border: 1px solid var(--border3);
  color: var(--pulse); font-size: .82rem; font-weight: 700;
  transition: all .25s var(--ease); margin-top: 4px;
}
.btn-order:hover {
  background: var(--gradglow); border-color: var(--pulse);
  transform: translateY(-1px); box-shadow: 0 4px 16px rgba(129,140,248,.2);
}
.btn-order:disabled { opacity: .35; cursor: not-allowed; transform: none; }

/* ── STORE HERO FIX ─────────────────────────────────────── */
.store-wrap {
  overflow-y: auto; padding: 24px 20px 40px; height: 100%;
}
.store-hero {
  text-align: center; margin-bottom: 20px;
  padding: 24px 20px;
  background: linear-gradient(135deg, rgba(129,140,248,.06), rgba(6,182,212,.04));
  border: 1px solid var(--border2); border-radius: var(--r-xl);
}
.store-hero h2 { font-size: 1.6rem; font-weight: 800; margin-bottom: 6px; }
.store-hero p { color: var(--text2); font-size: .85rem; }

.filter-bar {
  display: flex; flex-wrap: wrap; gap: 8px; padding: 0 2px 16px; overflow-x: auto;
}
.fpill {
  padding: 7px 16px; border-radius: 99px; font-size: .78rem; font-weight: 700;
  background: var(--surface); border: 1px solid var(--border2); color: var(--text2);
  transition: all .2s var(--ease2); cursor: pointer; white-space: nowrap;
}
.fpill:hover { border-color: var(--border3); color: var(--text); }
.fpill.active { background: rgba(129,140,248,.15); border-color: var(--pulse); color: var(--pulse); }

/* ── SCAN WRAP ──────────────────────────────────────────── */
.scan-wrap { overflow-y: auto; padding: 20px 16px 40px; height: 100%; }
.scan-hdr { text-align: center; margin-bottom: 20px; }
.scan-hdr h2 { font-size: 1.4rem; font-weight: 800; margin-bottom: 6px; }
.scan-notice {
  display: inline-block; padding: 6px 14px;
  background: rgba(129,140,248,.1); border: 1px solid rgba(129,140,248,.2);
  border-radius: 99px; font-size: .78rem; margin-top: 10px;
}
.scan-body { max-width: 580px; margin: 0 auto; }
.cam-frame {
  position: relative; background: var(--surface); border-radius: var(--r-xl);
  overflow: hidden; border: 1px solid var(--border2);
  max-height: 360px; margin-bottom: 16px;
}
.cam-guide {
  position: absolute; inset: 0; z-index: 5;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.guide-oval {
  width: 160px; height: 200px; border-radius: 50%;
  border: 2px dashed rgba(129,140,248,.5);
  box-shadow: 0 0 0 9999px rgba(0,0,0,.35);
}
.scan-line {
  position: absolute; left: 20%; right: 20%; height: 2px;
  background: linear-gradient(90deg, transparent, var(--pulse), var(--pulse2), transparent);
  animation: scanSweep 2.5s ease-in-out infinite;
  animation-play-state: paused;
  box-shadow: 0 0 10px var(--pulse);
}
@keyframes scanSweep {
  0%   { top: 15%; opacity: 1; }
  50%  { opacity: .7; }
  100% { top: 85%; opacity: 1; }
}
.guide-txt {
  position: absolute; bottom: 12px; width: 100%; text-align: center;
  font-size: .75rem; color: rgba(255,255,255,.7); font-weight: 600;
}
#camFeed { width: 100%; display: block; max-height: 360px; object-fit: cover; }
#scanCanvas { display: none; }
.scan-btns { display: flex; gap: 10px; justify-content: center; margin-bottom: 16px; flex-wrap: wrap; }
.sbtn {
  padding: 11px 22px; border-radius: var(--r-md); font-size: .84rem; font-weight: 700;
  transition: all .25s var(--ease); border: 1.5px solid transparent;
}
.sbtn.start { background: var(--grad); color: #fff; background-size: 200%; box-shadow: 0 4px 18px rgba(129,140,248,.3); }
.sbtn.start:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(129,140,248,.5); }
.sbtn.capture { background: linear-gradient(135deg, #06b6d4, #34d399); color: #fff; box-shadow: 0 4px 18px rgba(6,182,212,.3); }
.sbtn.capture:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(6,182,212,.5); }
.sbtn.stop { background: rgba(244,63,94,.1); border-color: rgba(244,63,94,.3); color: var(--red); }
.sbtn.stop:hover { background: rgba(244,63,94,.2); }
.sbtn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

.scan-opts { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--r-lg); padding: 16px; }
.scan-opts-title { font-size: .78rem; font-weight: 700; color: var(--text2); margin-bottom: 12px; text-transform: uppercase; letter-spacing: .05em; }
.cond-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.citem {
  display: flex; align-items: center; gap: 7px; padding: 7px 10px;
  border-radius: var(--r-sm); background: var(--surface2); border: 1px solid var(--border);
  font-size: .78rem; cursor: pointer; transition: all .2s;
}
.citem:hover { border-color: var(--border3); color: var(--pulse); }
.citem input { accent-color: var(--pulse); width: 14px; height: 14px; }

.scan-results { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--r-xl); padding: 20px; margin-top: 20px; }
.scan-results h3 { font-size: 1.1rem; font-weight: 800; margin-bottom: 14px; }
.scan-meta-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 16px; }
.result-card {
  background: var(--surface2); border: 1px solid var(--border); border-left: 3px solid var(--pulse);
  border-radius: var(--r-md); padding: 14px; margin-bottom: 10px;
}
.rc-head { display: flex; align-items: center; gap: 9px; margin-bottom: 8px; flex-wrap: wrap; }
.rc-badge { font-size: .65rem; font-weight: 800; padding: 2px 8px; border-radius: 99px; margin-left: auto; }
.rc-body p { font-size: .82rem; color: var(--text2); line-height: 1.55; margin-bottom: 5px; }
.rc-body p strong { color: var(--text); }
.scan-disclaimer {
  background: rgba(245,158,11,.08); border: 1px solid rgba(245,158,11,.2);
  border-radius: var(--r-sm); padding: 12px; font-size: .78rem; color: var(--amber);
  line-height: 1.55; margin-top: 14px;
}

/* ── PROFILE WRAP ───────────────────────────────────────── */
.profile-wrap { overflow-y: auto; padding: 20px 16px 40px; height: 100%; }
.prof-banner {
  display: flex; align-items: center; gap: 20px;
  padding: 24px 20px; background: var(--surface);
  border: 1px solid var(--border2); border-radius: var(--r-xl);
  margin-bottom: 16px; position: relative; overflow: hidden;
}
.prof-banner::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(129,140,248,.6), transparent);
}
.prof-av-ring { position: relative; cursor: pointer; }
.prof-av {
  width: 72px; height: 72px; border-radius: 50%; overflow: hidden;
  background: var(--grad); display: flex; align-items: center; justify-content: center;
  border: 3px solid var(--surface3);
  box-shadow: 0 0 24px rgba(129,140,248,.25);
}
.av-edit {
  position: absolute; bottom: 0; right: 0;
  width: 24px; height: 24px; border-radius: 50%; background: var(--surface2);
  border: 2px solid var(--surface); display: flex; align-items: center; justify-content: center;
  font-size: .75rem;
}
.prof-info { flex: 1; }
.prof-info h2 { font-size: 1.3rem; font-weight: 800; margin-bottom: 4px; }
.prof-info p { font-size: .82rem; color: var(--muted); margin-bottom: 8px; }
.plan-tag { display: inline-block; padding: 3px 12px; border-radius: 99px; font-size: .72rem; font-weight: 800; }

.stats-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; margin-bottom: 16px; }
.stat {
  background: var(--surface); border: 1px solid var(--border2); border-radius: var(--r-md);
  padding: 14px 10px; text-align: center;
}
.sv { font-size: 1.5rem; font-weight: 800; background: var(--grad); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.sl { font-size: .68rem; color: var(--muted); margin-top: 3px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }

.usage-card { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--r-lg); padding: 18px; margin-bottom: 16px; }
.usage-title { font-size: .78rem; font-weight: 800; color: var(--text2); margin-bottom: 14px; text-transform: uppercase; letter-spacing: .06em; }
.usage-row { display: flex; align-items: center; gap: 10px; font-size: .8rem; margin-bottom: 10px; }
.usage-row:last-child { margin-bottom: 0; }
.usage-bar { flex: 1; height: 6px; background: var(--surface2); border-radius: 99px; overflow: hidden; }
.usage-fill { height: 100%; border-radius: 99px; background: var(--pulse); transition: width .6s var(--ease2); }
.usage-row span:first-child { min-width: 70px; }
.usage-row span:last-child { min-width: 45px; text-align: right; color: var(--muted); font-size: .76rem; }

.plans-section { margin-bottom: 16px; }
.section-title { font-size: .82rem; font-weight: 800; color: var(--text2); margin-bottom: 12px; text-transform: uppercase; letter-spacing: .06em; }
.plans-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.plan-card {
  background: var(--surface); border: 1.5px solid var(--border2);
  border-radius: var(--r-lg); padding: 16px;
  transition: all .3s var(--ease);
}
.plan-card.active { border-color: var(--pcolor, var(--pulse)); box-shadow: 0 0 24px rgba(129,140,248,.1); }
.plan-card:hover { transform: translateY(-2px); border-color: var(--pcolor, var(--pulse)); }
.pc-head { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.pc-ico { font-size: 1.4rem; }
.pc-name { font-size: .85rem; font-weight: 800; }
.pc-price { font-size: .72rem; color: var(--muted); margin-top: 2px; }
.pc-active { margin-left: auto; font-size: .65rem; padding: 2px 8px; border-radius: 99px; background: rgba(52,211,153,.15); color: var(--green); font-weight: 800; }
.pc-feats { margin-bottom: 12px; }
.pcf { font-size: .75rem; color: var(--text2); padding: 3px 0; }
.btn-plan {
  width: 100%; padding: 9px; border-radius: var(--r-sm);
  background: var(--gradsoft); border: 1px solid var(--border3);
  color: var(--pulse); font-size: .78rem; font-weight: 700;
  transition: all .25s var(--ease);
}
.btn-plan:hover { background: var(--gradglow); border-color: var(--pulse); transform: translateY(-1px); }
.btn-plan.current { opacity: .5; cursor: not-allowed; transform: none; }
.btn-plan:disabled { opacity: .45; cursor: not-allowed; }

.prof-section { background: var(--surface); border: 1px solid var(--border2); border-radius: var(--r-lg); padding: 18px; }

/* ── MODAL IMPROVEMENTS ─────────────────────────────────── */
.modal {
  position: fixed; inset: 0; z-index: 300;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.7);
  backdrop-filter: blur(12px);
  padding: 16px;
  animation: fadeIn .25s ease both;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.modal-box {
  background: var(--surface); border: 1px solid var(--border2);
  border-radius: var(--r-xl); overflow: hidden;
  width: 100%; max-width: 820px; max-height: 88dvh;
  display: flex; flex-direction: column;
  box-shadow: var(--shadow), 0 0 60px rgba(129,140,248,.08);
  animation: modalSlideIn .35s var(--ease3) both;
}
.modal-sm { max-width: 440px; }
.modal-head {
  display: flex; align-items: center; gap: 10px; padding: 16px 20px;
  border-bottom: 1px solid var(--border); flex-shrink: 0;
  background: var(--surface2);
}
.modal-title { font-weight: 800; font-size: .95rem; }
.modal-tabs { display: flex; gap: 4px; margin-left: auto; }
.mtab {
  padding: 5px 14px; border-radius: var(--r-sm); font-size: .78rem; font-weight: 700;
  color: var(--muted); transition: all .2s; background: none;
}
.mtab.active { background: rgba(129,140,248,.12); color: var(--pulse); }
.modal-x {
  width: 30px; height: 30px; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: .9rem; transition: all .2s;
  margin-left: auto;
}
.modal-x:hover { background: rgba(244,63,94,.12); color: var(--red); }
.modal-tabs + .modal-x { margin-left: 0; }
.modal-body { flex: 1; overflow-y: auto; }
.web-preview { height: 100%; min-height: 400px; }
#previewIframe { width: 100%; height: 100%; border: none; min-height: 400px; }
.web-code { height: 100%; }
.code-acts { display: flex; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--border); }
.code-acts button { padding: 6px 14px; border-radius: var(--r-sm); background: var(--surface2); border: 1px solid var(--border2); font-size: .78rem; font-weight: 700; color: var(--text2); transition: all .2s; }
.code-acts button:hover { color: var(--pulse); border-color: var(--border3); }
#webCodePre { padding: 16px; overflow: auto; font-family: 'JetBrains Mono', monospace; font-size: .78rem; color: #a5b4fc; }

/* Qty Control */
.qty-row { display: flex; align-items: center; justify-content: space-between; margin: 10px 0; }
.qty-row label { font-size: .8rem; font-weight: 700; color: var(--text2); }
.qty-ctrl { display: flex; align-items: center; gap: 8px; }
.qty-ctrl button { width: 28px; height: 28px; border-radius: 50%; background: var(--surface2); border: 1px solid var(--border2); font-size: 1.1rem; font-weight: 700; color: var(--text); display: flex; align-items: center; justify-content: center; transition: all .2s; }
.qty-ctrl button:hover { background: var(--surface3); border-color: var(--border3); color: var(--pulse); }
.qty-ctrl span { font-size: 1rem; font-weight: 800; min-width: 24px; text-align: center; }
.order-total { font-size: 1.05rem; font-weight: 800; color: var(--pulse); padding: 10px; background: rgba(129,140,248,.07); border-radius: var(--r-sm); text-align: center; }

/* ── TOASTS ─────────────────────────────────────────────── */
#toasts { position: fixed; bottom: calc(var(--nav-h) + 14px); right: 16px; z-index: 9999; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
@media (min-width: 769px) { #toasts { bottom: 20px; } }
.toast {
  padding: 11px 18px; border-radius: var(--r-md);
  font-size: .83rem; font-weight: 600; color: #fff;
  transform: translateX(120%); transition: transform .35s var(--ease3), opacity .35s;
  max-width: 320px; pointer-events: all;
  box-shadow: 0 6px 24px rgba(0,0,0,.4);
  display: flex; align-items: center; gap: 8px;
}
.toast.show { transform: translateX(0); }
.toast.out { transform: translateX(120%); opacity: 0; }
.toast.success { background: linear-gradient(135deg, #059669, #10b981); }
.toast.error   { background: linear-gradient(135deg, #dc2626, #f43f5e); }
.toast.info    { background: linear-gradient(135deg, #4338ca, #0e7490); }

/* ── DESKTOP TOPBAR SHOW NAV ────────────────────────────── */
@media (min-width: 769px) {
  .bottom-nav { display: none !important; }
  .topbar-nav { display: flex !important; }
  .layout {
    height: calc(100dvh - var(--topbar-h));
  }
  #tabChat, .tab {
    height: calc(100dvh - var(--topbar-h));
  }
  .store-wrap, .scan-wrap, .profile-wrap { padding-bottom: 24px; }
}
