/* Rank badge styles */
.rankBadge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 0.95em;
  font-weight: 600;
  vertical-align: middle;
  background: linear-gradient(90deg, #00e6ff 0%, #7f53ff 100%);
  color: #fff;
  box-shadow: 0 1px 6px 0 rgba(0,0,0,0.18), 0 0 12px rgba(0,230,255,0.2);
  letter-spacing: 0.04em;
  transition: transform 0.15s cubic-bezier(.4,2,.6,1), box-shadow 0.15s, all 0.3s ease;
  animation: badgeGlow 3s ease-in-out infinite;
  position: relative;
}

.rankBadge:hover {
  transform: scale(1.05) translateY(-2px);
  box-shadow: 0 2px 12px 0 rgba(0,230,255,0.35), 0 0 20px rgba(0,230,255,0.3);
  animation: badgePulse 0.6s ease-in-out;
}

@keyframes badgeGlow {
  0%, 100% { 
    box-shadow: 0 1px 6px 0 rgba(0,0,0,0.18), 0 0 12px rgba(0,230,255,0.2);
  }
  50% { 
    box-shadow: 0 1px 6px 0 rgba(0,0,0,0.18), 0 0 20px rgba(0,230,255,0.35);
  }
}

@keyframes badgePulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

.rankBadge.rank-elite {
  background: linear-gradient(90deg, #ff5ecd 0%, #ffb86c 100%);
  color: #fff;
  box-shadow: 0 2px 12px 0 rgba(255,94,205,0.28), 0 0 12px rgba(255,94,205,0.2);
}
.rankBadge.rank-elite:hover {
  box-shadow: 0 2px 12px 0 rgba(255,94,205,0.35), 0 0 20px rgba(255,94,205,0.3);
}

.rankBadge.rank-diamond {
  background: linear-gradient(90deg, #00e6ff 0%, #7f53ff 100%);
}

.rankBadge.rank-gold {
  background: linear-gradient(90deg, #ffe066 0%, #ffb86c 100%);
  color: #222;
  box-shadow: 0 2px 12px 0 rgba(255,200,0,0.28), 0 0 12px rgba(255,200,0,0.2);
}
.rankBadge.rank-gold:hover {
  box-shadow: 0 2px 12px 0 rgba(255,200,0,0.35), 0 0 20px rgba(255,200,0,0.3);
}

.rankBadge.rank-silver {
  background: linear-gradient(90deg, #e0e0e0 0%, #bdbdbd 100%);
  color: #222;
  box-shadow: 0 2px 12px 0 rgba(192,192,192,0.28), 0 0 12px rgba(192,192,192,0.2);
}
.rankBadge.rank-silver:hover {
  box-shadow: 0 2px 12px 0 rgba(192,192,192,0.35), 0 0 20px rgba(192,192,192,0.3);
}

.rankBadge.rank-bronze {
  background: linear-gradient(90deg, #e0a96d 0%, #c97b3b 100%);
  color: #fff;
  box-shadow: 0 2px 12px 0 rgba(184,115,51,0.28), 0 0 12px rgba(184,115,51,0.2);
}
.rankBadge.rank-bronze:hover {
  box-shadow: 0 2px 12px 0 rgba(184,115,51,0.35), 0 0 20px rgba(184,115,51,0.3);
}

.rankBadge::before {
  content: '';
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 8px;
  background: currentColor;
  opacity: 0.7;
  box-shadow: 0 0 8px 2px currentColor;
  animation: badgeDot 2s ease-in-out infinite;
}

@keyframes badgeDot {
  0%, 100% { 
    box-shadow: 0 0 8px 2px currentColor;
  }
  50% { 
    box-shadow: 0 0 12px 4px currentColor;
  }
}
/* Chat message styles */
.chatMessage {
  display: flex;
  align-items: center;
  margin-bottom: 14px;
  padding: 0 0 0 0;
  gap: 10px;
  animation: slideInLeft 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.chatUser {
  font-weight: 700;
  color: var(--accent);
  margin-right: 2px;
  font-size: 1.08em;
  display: flex;
  align-items: center;
  text-shadow: 0 0 10px rgba(0,230,255,0.2);
}

.chatText {
  color: var(--text);
  font-size: 1.08em;
  word-break: break-word;
  line-height: 1.4;
}

.chatMessage:nth-child(1) { animation-delay: 0.05s; }
.chatMessage:nth-child(2) { animation-delay: 0.1s; }
.chatMessage:nth-child(3) { animation-delay: 0.15s; }
.chatMessage:nth-child(n+4) { animation-delay: 0.2s; }

.chatMessage:hover .chatUser {
  text-shadow: 0 0 15px rgba(0,230,255,0.4);
}
/* Main panel styles - responsive and larger on desktop */
.panel {
  background: var(--panel);
  border-radius: 18px;
  box-shadow: 0 4px 32px 0 rgba(0,0,0,0.18);
  padding: 40px 48px 40px 48px;
  margin: 0 auto;
  max-width: 1400px;
  min-width: 340px;
  width: 98vw;
  animation: panelEntrance 700ms cubic-bezier(.4,2,.6,1);
  position: relative;
  overflow: hidden;
  transition: max-width 0.3s, padding 0.3s;
}
@media (max-width: 1200px) {
  .panel {
    max-width: 98vw;
    padding: 24px 8px 24px 8px;
  }
}
@media (max-width: 800px) {
  .panel {
    max-width: 100vw;
    padding: 8px 2vw 8px 2vw;
    border-radius: 10px;
  }
}
/* Custom checkbox styling for auto-withdraw toggle */
input[type="checkbox"]#autoWithdrawToggle{
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(0,230,255,0.30);
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.005));
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}
input[type="checkbox"]#autoWithdrawToggle:hover{
  border-color: rgba(0,230,255,0.50);
  box-shadow: 0 0 12px rgba(0,230,255,0.06);
}
input[type="checkbox"]#autoWithdrawToggle:checked{
  background: linear-gradient(90deg, rgba(0,230,255,0.20), rgba(59,224,201,0.12));
  border-color: rgba(0,230,255,0.60);
  box-shadow: 0 0 16px rgba(0,230,255,0.10);
}
input[type="checkbox"]#autoWithdrawToggle:checked::after{
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--accent);
  font-weight: 800;
  font-size: 12px;
}

/* Custom checkbox styling for minimum redeposit toggle */
input[type="checkbox"]#minRedepositsToggle{
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(0,230,255,0.30);
  border-radius: 3px;
  background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.005));
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}
input[type="checkbox"]#minRedepositsToggle:hover{
  border-color: rgba(0,230,255,0.50);
  box-shadow: 0 0 10px rgba(0,230,255,0.05);
}
input[type="checkbox"]#minRedepositsToggle:checked{
  background: linear-gradient(90deg, rgba(0,230,255,0.20), rgba(59,224,201,0.12));
  border-color: rgba(0,230,255,0.60);
  box-shadow: 0 0 12px rgba(0,230,255,0.10);
}
input[type="checkbox"]#minRedepositsToggle:checked::after{
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--accent);
  font-weight: 800;
  font-size: 11px;
}
:root {
  --bg-1: #00121a;
  --bg-2: #012233;
  --panel: #042735;
  --muted: #89c2d9;
  --accent: #00e6ff;
  --accent-2: #3be0c9;
  --glass: rgba(255, 255, 255, 0.04);
  --text: #e6f7fb;
  --panel-min-width: 900px;
  --panel-max-width: 1400px;
  /* Enhanced elevation system */
  --shadow-0: none;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.12);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.15);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.18);
  --shadow-xl: 0 12px 32px rgba(0,0,0,0.20);
  --shadow-2xl: 0 20px 60px rgba(0,0,0,0.24);
  --shadow-hover: 0 0 40px rgba(0,230,255,0.15);
  /* Color palette expansion */
  --color-success: #14f195;
  --color-warning: #ffd27f;
  --color-error: #ff7e8f;
  --color-info: #7ec8ff;
  --color-premium: #ff5ecd;
}

/* Modern statistics controls - Enhanced */
.toggle-group, .filter-group {
  display: flex;
  gap: 6px;
  background: linear-gradient(90deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
  padding: 6px;
  border-radius: 14px;
  border: 1px solid rgba(0,230,255,0.12);
  box-shadow: 0 4px 16px rgba(0,0,0,0.15), inset 0 1px 0 rgba(255,255,255,0.06);
}

/* Auto-withdraw delay input styling */
input#autoWithdrawDelay{
  -moz-appearance: textfield;
  appearance: textfield;
  width: 72px;
  padding: 6px 8px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.02);
  color: var(--text);
  font-weight: 600;
  font-size: 13px;
  margin-left: 8px;
  transition: box-shadow 0.18s, border-color 0.18s, transform 0.12s;
}
input#autoWithdrawDelay:focus{ outline: none; border-color: rgba(0,230,255,0.45); box-shadow: 0 6px 24px rgba(0,230,255,0.06); transform: translateY(-1px); }
input#autoWithdrawDelay::-webkit-outer-spin-button, input#autoWithdrawDelay::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* Compact wrapper for auto-withdraw control to keep layout tidy */
.auto-withdraw-wrap{ display:inline-flex; align-items:center; gap:8px; }

/* Slight refinements for log withdraw buttons */
.logWithdrawBtn{ padding:8px 14px; border-radius:10px; font-size:13px; }
.logWithdrawBtn:disabled{ opacity:0.6; filter:grayscale(0.08); }

/* Make stats controls wrap nicely on small widths */
.statsControls{ flex-wrap:wrap; align-items:center; }

.toggle-btn, .filter-btn {
  padding: 10px 18px;
  border: none;
  background: transparent;
  color: rgba(230,255,255,0.65);
  cursor: pointer;
  border-radius: 10px;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: -0.2px;
  transition: all 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
  box-shadow: none;
  position: relative;
  overflow: hidden;
}

.toggle-btn::before, .filter-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--x, 0), rgba(255,255,255,0.2), transparent 80%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.toggle-btn:hover, .filter-btn:hover {
  background: rgba(0,230,255,0.1);
  color: rgba(255,255,255,0.95);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,230,255,0.1);
}

.toggle-btn.active, .filter-btn.active {
  background: linear-gradient(135deg, rgba(0,230,255,0.22), rgba(59,224,201,0.16));
  color: #fff;
  border: 1px solid rgba(0,230,255,0.32);
  box-shadow: 0 6px 20px rgba(0,230,255,0.14), inset 0 1px 0 rgba(255,255,255,0.12);
  animation: activePulse 0.4s ease-out;
}

@keyframes activePulse {
  0% { transform: scale(0.95); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  background: radial-gradient(ellipse at 20% 10%, rgba(2,45,66,0.28), transparent 10%),
              linear-gradient(180deg,var(--bg-1) 0%, var(--bg-2) 100%);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* subtle shimmer */
body::before{
  content: "";
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 75% 10%, rgba(3,176,200,0.06), transparent 10%),
              radial-gradient(circle at 10% 80%, rgba(0,230,255,0.04), transparent 12%);
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: screen;
}

/* Panel */
.panel{
  position: relative;
  width: clamp(var(--panel-min-width), 90vw, var(--panel-max-width));
  max-width: 95vw;
  min-height: clamp(520px, 75vh, 880px);
  border-radius: 24px;
  padding: 28px;
  /* Darker, richer background to match rank panel */
  background: linear-gradient(180deg, rgba(4,39,53,0.88), rgba(0,18,35,0.88));
  border: 1px solid rgba(207,242,247,0.04);
  box-shadow:
    0 28px 90px rgba(0,0,0,0.65),
    0 0 120px rgba(0,230,255,0.045),
    inset 0 2px 10px rgba(207,242,247,0.02),
    var(--shadow-2xl);
  backdrop-filter: blur(6px) saturate(120%);
  z-index: 1;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 300ms ease;
}

/* ==================== ENHANCED ANIMATIONS LIBRARY ==================== */

/* Entrance animations */
@keyframes panelEntrance{ 
  0%{ transform: translateY(10px) scale(0.995); opacity:0 } 
  60%{ transform: translateY(-6px) scale(1.002); opacity:1 } 
  100%{ transform: translateY(0) scale(1); opacity:1 } 
}

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

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

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

@keyframes fadeInScale {
  from { opacity: 0; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1); }
}

/* Hover & interaction animations */
@keyframes accentDrift{ 
  0%{ transform: translateY(0) rotate(0deg); } 
  50%{ transform: translateY(8px) rotate(6deg); } 
  100%{ transform: translateY(0) rotate(0deg); } 
}

@keyframes lift {
  from { transform: translateY(0); }
  to { transform: translateY(-4px); }
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 10px rgba(0,230,255,0.3), inset 0 0 10px rgba(0,230,255,0.1); }
  50% { box-shadow: 0 0 20px rgba(0,230,255,0.6), inset 0 0 20px rgba(0,230,255,0.2); }
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(0,230,255,0.7); }
  50% { box-shadow: 0 0 0 10px rgba(0,230,255,0); }
}

/* Ripple effect */
@keyframes rippleExpand {
  from { transform: translate(-50%, -50%) scale(0); opacity: 1; }
  to { transform: translate(-50%, -50%) scale(6); opacity: 0; }
}

/* Shimmer effect */
@keyframes shimmer {
  0% { background-position: -1000px 0; }
  100% { background-position: 1000px 0; }
}

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

/* Bounce animations */
@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes countBounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

/* Spin animation */
@keyframes spin { 
  0%{ transform: rotate(0deg); } 
  100%{ transform: rotate(360deg); } 
}

@keyframes spinReverse {
  0%{ transform: rotate(360deg); }
  100%{ transform: rotate(0deg); }
}

/* Status animations */
@keyframes checkmark {
  0% { stroke-dashoffset: 100; }
  100% { stroke-dashoffset: 0; }
}

@keyframes successPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); }
}

/* Progress animations */
@keyframes progressFill {
  0% { width: 0%; opacity: 0.5; }
  50% { opacity: 1; }
  100% { opacity: 1; }
}

/* Panel entrance and drifting accent */
.panel{ animation: panelEntrance 700ms cubic-bezier(.16,.9,.24,1) both; }
.panel::before{ content: ''; position: absolute; left: -60px; top: -80px; width: 480px; height: 480px; background: radial-gradient(circle at 30% 30%, rgba(0,230,255,0.03), transparent 30%); transform: rotate(0deg); pointer-events: none; z-index: 0; animation: accentDrift 14s linear infinite; }

/* panel split: left content + right chat column */
.layout{
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 24px;
  align-items: start;
  margin-top: 8px;
}

/* Decorative accent inside panel to mirror rank shimmer */
.panel::after{
  content: '';
  position: absolute;
  right: -80px;
  top: -30px;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle at 30% 30%, rgba(207,242,247,0.06), transparent 40%);
  transform: rotate(12deg);
  pointer-events: none;
  z-index: 0;
}

.chatColumn{
  width: 100%;
  max-width: 380px;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.008));
  border-radius: 16px;
  padding: 18px;
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.04),
    0 4px 24px rgba(0,0,0,0.2);
  border: 1px solid rgba(255,255,255,0.05);
  transition: transform 0.2s ease;
}

.chatHeader{ display:flex; align-items:center; gap:8px; margin-bottom:8px; }

.chatBox{
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 8px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.005));
  border:1px solid rgba(255,255,255,0.02);
  scrollbar-width: thin;
  scrollbar-color: rgba(0,230,255,0.4) rgba(255,255,255,0.03);
}
.chatBox::-webkit-scrollbar{ width: 10px; }
.chatBox::-webkit-scrollbar-track{ background: rgba(255,255,255,0.02); border-radius: 10px; }
.chatBox::-webkit-scrollbar-thumb{ background: linear-gradient(180deg, rgba(0,230,255,0.25), rgba(59,224,201,0.18)); border-radius: 10px; border: 2px solid rgba(255,255,255,0.02); }

.chatInput{ display:flex; gap:8px; margin-top:10px; }
.chatInput input{ flex:1; padding:10px 12px; border-radius:10px; border:1px solid rgba(255,255,255,0.04); background: rgba(255,255,255,0.01); color:var(--text); }
.chatInput button{ padding:10px 12px; border-radius:10px; border:none; background: linear-gradient(90deg,var(--accent),var(--accent-2)); color:#012; font-weight:700; cursor:pointer; }

/* Header */
.header{ 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  gap: 20px; 
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.brand{ 
  display: flex; 
  gap: 16px; 
  align-items: center; 
}
.logo{
  width: 64px; 
  height: 64px; 
  border-radius: 16px; 
  object-fit: cover; 
  display: block;
  /* show the SVG transparency (no turquoise background) */
  background: transparent;
  box-shadow: 
    0 12px 28px rgba(0,0,0,0.3),
    0 0 16px rgba(0,230,255,0.08),
    0 0 0 1px rgba(255,255,255,0.05);
  border: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.logo:hover {
  transform: translateY(-2px);
  box-shadow: 
    0 16px 32px rgba(0,0,0,0.35),
    0 0 24px rgba(0,230,255,0.12),
    0 0 0 1px rgba(255,255,255,0.08);
}

/* small logo used in auth dialog */
.authLogo{ 
  width: 52px; 
  height: 52px; 
  border-radius: 12px; 
  object-fit: cover;
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}
.title{ 
  font-weight: 700; 
  color: var(--text); 
  font-size: 22px;
  letter-spacing: -0.3px;
  text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* Account */
.account{ display:flex; gap:12px; align-items:center; }
.userChip{
  display:flex; align-items:center; gap:10px; padding:8px 12px; border-radius:999px;
  background: linear-gradient(90deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  border:1px solid rgba(255,255,255,0.03); color:var(--text); font-weight:600; font-size:14px;
}
.logoutBtn{
  background:transparent; color:var(--muted); border:1px solid rgba(255,255,255,0.03);
  padding:8px 12px; border-radius:10px; cursor:pointer; transition: background .12s, color .12s, transform .12s;
}
.logoutBtn:hover{ transform:translateY(-3px); color:var(--text); }

/* Tabs - Enhanced navbar styling */
.tabs{ 
  display: flex; 
  gap: 12px; 
  align-items: center; 
  margin: 12px 0 24px 0;
  padding: 14px 18px;
  background: linear-gradient(90deg, rgba(255,255,255,0.02), rgba(255,255,255,0.008));
  border-radius: 18px;
  border: 1px solid rgba(0,230,255,0.08);
  box-shadow: 0 8px 32px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,255,255,0.04);
  flex-wrap: wrap;
  backdrop-filter: blur(8px);
}
.tab{
  position: relative;
  padding: 12px 22px;
  border-radius: 12px;
  background: transparent;
  color: rgba(230,255,255,0.6);
  font-weight: 700;
  letter-spacing: -0.3px;
  cursor: pointer;
  user-select: none;
  border: 1px solid transparent;
  transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
  overflow: hidden;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.tab::before {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.tab:hover{ 
  transform: translateY(-2px); 
  color: rgba(255,255,255,0.95);
  background: rgba(0,230,255,0.08);
  border-color: rgba(0,230,255,0.2);
  box-shadow: 0 8px 24px rgba(0,230,255,0.12);
}

.tab:active{ 
  transform: translateY(-1px); 
  transition-duration: 0.1s;
}

.tab:focus{ 
  outline: none; 
  color: rgba(255,255,255,0.95);
  box-shadow: 0 8px 24px rgba(0,230,255,0.12);
}

.tab[aria-selected="true"]{
  color: #fff;
  background: linear-gradient(135deg, rgba(0,230,255,0.2), rgba(59,224,201,0.15));
  box-shadow: 
    0 12px 36px rgba(0,230,255,0.2),
    0 0 40px rgba(0,230,255,0.12),
    inset 0 1px 0 rgba(255,255,255,0.15);
  border: 1px solid rgba(0,230,255,0.35);
}

.tab[aria-selected="true"]::before{
  transform: scaleX(1);
}

.tab[aria-selected="true"]::after{
  content:""; position:absolute; left:8px; right:8px; bottom:-8px; height:6px; border-radius:6px;
  background: linear-gradient(90deg, rgba(0,230,255,0.18), rgba(59,224,201,0.1)); filter:blur(8px); opacity:1;
}

/* ripple */
.ripple{ position:absolute; border-radius:50%; transform: translate(-50%,-50%) scale(0); pointer-events:none;
  background: radial-gradient(circle, rgba(255,255,255,0.18) 0%, rgba(255,255,255,0.02) 50%, transparent 60%);
  animation: ripple .6s ease-out forwards;
}
@keyframes ripple{ to{ transform: translate(-50%,-50%) scale(6); opacity:0; } }

/* Content */
.content{
  margin-top: 16px;
  padding: 32px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.006));
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.03),
    0 4px 24px rgba(0,0,0,0.1);
  color: #cfeff7;
  flex: 1;
  min-height: 320px;
  overflow: auto;
  border: 1px solid rgba(255,255,255,0.04);
}

/* Logs list: constrain height and make scrollable */
.logsList{
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px;
  background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.005));
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.03);
  /* limit height so it doesn't fill the whole panel */
  max-height: calc(70vh - 160px);
  overflow-y: auto;
  padding-bottom: 84px; /* room for bottom toolbar */
}

/* Toolbar that stays visible while scrolling inside logs list */
.logsToolbar{
  position: sticky;
  bottom: 12px;
  z-index: 12;
  display: flex;
  justify-content: flex-end;
  padding: 10px 12px;
  gap: 10px;
  backdrop-filter: blur(6px) saturate(120%);
  background: linear-gradient(180deg, rgba(2,16,20,0.62), rgba(2,16,20,0.36));
  border-radius: 12px;
  margin-top: 6px;
  margin-left: auto;
  margin-right: 6px;
  border: 1px solid rgba(255,255,255,0.04);
  box-shadow: 0 6px 26px rgba(0,0,0,0.45);
}

/* Secondary button style for export */
.btnSecondary{
  padding:10px 14px; border-radius:12px; border:1px solid rgba(255,255,255,0.06); background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.002)); color:var(--text); font-weight:800; cursor:pointer; min-width:90px;
}
.btnSecondary:hover{ transform: translateY(-2px); box-shadow: 0 12px 36px rgba(0,200,220,0.06); }

/* Danger variant that matches primary sizing but uses warning gradient */
.btnDanger {
  padding: 10px 14px;
  border-radius: 12px;
  border: 1.5px solid var(--accent);
  background: linear-gradient(90deg, rgba(255,107,107,0.18), rgba(0,230,255,0.10));
  color: var(--accent);
  font-weight: 800;
  cursor: pointer;
  min-width: 90px;
  box-shadow: 0 2px 12px rgba(0,230,255,0.08);
  transition: all 0.18s;
}
.btnDanger:hover {
  background: linear-gradient(90deg, rgba(0,230,255,0.22), rgba(255,107,107,0.22));
  color: #fff;
  border-color: var(--accent-2);
  box-shadow: 0 8px 32px rgba(0,230,255,0.18);
  transform: translateY(-2px) scale(1.04);
}

/* Make toolbar buttons visually match the main action style */
.logsToolbar .btnPrimary, .logsToolbar .btnSecondary, .logsToolbar .btnDanger{ height:40px; align-items:center; display:inline-flex; justify-content:center; }

/* Scrollbar styling for webkit browsers */
.logsList::-webkit-scrollbar{ width:12px; }
.logsList::-webkit-scrollbar-track{ background: rgba(255,255,255,0.01); border-radius:8px; }
.logsList::-webkit-scrollbar-thumb{ background: linear-gradient(180deg, rgba(0,230,255,0.18), rgba(59,224,201,0.12)); border-radius:8px; border:2px solid rgba(0,0,0,0.06); }
.logsList::-webkit-scrollbar-thumb:hover{ background: linear-gradient(180deg, rgba(0,230,255,0.28), rgba(59,224,201,0.18)); }

/* scrollbar color for Firefox */
.logsList{ scrollbar-color: rgba(0,230,255,0.18) rgba(255,255,255,0.02); scrollbar-width: thin; }

.logEntry{
  padding: 12px;
  border-radius: 10px;
  background: linear-gradient(90deg, rgba(0,230,255,0.02), rgba(59,224,201,0.01));
  border: 1px solid rgba(0,230,255,0.04);
  color: var(--text);
  animation: slideInLeft 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
  transition: all 0.2s ease;
  position: relative;
  left-border-color: rgba(0,230,255,0.3);
  border-left: 3px solid rgba(0,230,255,0.1);
}

.logEntry:nth-child(1) { animation-delay: 0.05s; }
.logEntry:nth-child(2) { animation-delay: 0.1s; }
.logEntry:nth-child(3) { animation-delay: 0.15s; }
.logEntry:nth-child(n+4) { animation-delay: 0.2s; }

.logEntry:hover {
  border-left-color: rgba(0,230,255,0.6);
  transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(0,210,220,0.08);
  background: linear-gradient(90deg, rgba(0,230,255,0.05), rgba(59,224,201,0.02));
}

.logEntry pre{ 
  max-height: 160px; 
  overflow: auto; 
  margin: 8px 0 0 0; 
  padding: 8px; 
  background: rgba(0,0,0,0.06); 
  border-radius: 8px; 
}

.logsList .small{ color: rgba(230,255,255,0.8); }

/* Highlight / glow animation for new logs */
@keyframes glowPulse {
  0% { box-shadow: 0 0 0px rgba(0,230,255,0.0); transform: translateY(0); }
  30% { box-shadow: 0 8px 28px rgba(0,230,255,0.14); transform: translateY(-4px); }
  100% { box-shadow: 0 0 0px rgba(0,230,255,0.0); transform: translateY(0); }
}
.logEntry.highlight{
  animation: glowPulse 1.2s ease-in-out 1;
  border-color: rgba(0,230,255,0.22);
  background: linear-gradient(90deg, rgba(0,230,255,0.06), rgba(59,224,201,0.02));
}

/* Stronger flash for newly received entries (used for the newest item) */
@keyframes flashPulse {
  0% { background: linear-gradient(90deg, rgba(0,230,255,0.18), rgba(59,224,201,0.08)); transform: translateY(-2px); }
  40% { background: linear-gradient(90deg, rgba(0,230,255,0.10), rgba(59,224,201,0.04)); transform: translateY(-6px); box-shadow: 0 18px 48px rgba(0,210,220,0.18); }
  100% { background: linear-gradient(90deg, rgba(0,230,255,0.06), rgba(59,224,201,0.02)); transform: translateY(0); box-shadow: none; }
}
.logEntry.new-flash{ animation: flashPulse 900ms ease-in-out 1; border-color: rgba(0,230,255,0.28); }

/* Hover animations */
.logEntry:hover{
  transform: translateY(-4px);
  transition: transform 180ms ease, box-shadow 180ms ease;
  box-shadow: 0 12px 36px rgba(0,210,220,0.08);
  border-color: rgba(0,230,255,0.12);
}

.logBadge{ display:inline-block; padding:4px 8px; border-radius:999px; background:rgba(0,230,255,0.12); color:#001; font-weight:700; margin-left:8px; font-size:12px }

/* Custom checkbox styling for auto-scroll toggle */
input[type="checkbox"]#autoScrollToggle{
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(0,230,255,0.30);
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.005));
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
}
input[type="checkbox"]#autoScrollToggle:hover{
  border-color: rgba(0,230,255,0.50);
  box-shadow: 0 0 12px rgba(0,230,255,0.06);
}
input[type="checkbox"]#autoScrollToggle:checked{
  background: linear-gradient(90deg, rgba(0,230,255,0.20), rgba(59,224,201,0.12));
  border-color: rgba(0,230,255,0.60);
  box-shadow: 0 0 16px rgba(0,230,255,0.10);
}
input[type="checkbox"]#autoScrollToggle:checked::after{
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--accent);
  font-weight: 800;
  font-size: 12px;
}

/* Withdraw button for log entries */
.logWithdrawBtn{
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(0,230,255,0.15);
  background: linear-gradient(90deg, rgba(0,230,255,0.08), rgba(59,224,201,0.05));
  color: var(--accent);
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.logWithdrawBtn:hover{
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,230,255,0.12);
  background: linear-gradient(90deg, rgba(0,230,255,0.12), rgba(59,224,201,0.08));
  border-color: rgba(0,230,255,0.30);
}
.logWithdrawBtn:disabled{
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* Completion marker animation */
@keyframes completePulse {
  0% { opacity: 0; transform: scale(0.8); }
  50% { opacity: 1; }
  100% { opacity: 0.8; transform: scale(1); }
}
.logEntry.withdrawn{
  border-color: rgba(107,242,120,0.60);
  background: linear-gradient(90deg, rgba(107,242,120,0.08), rgba(59,224,201,0.05));
  animation: withdrawSuccess 0.8s cubic-bezier(0.36, 0, 0.66, -0.56) 1;
  box-shadow: 0 0 20px rgba(107,242,120,0.3), inset 0 0 15px rgba(107,242,120,0.05);
}
.logEntry.withdrawn::before{
  content: '✓';
  display: inline-block;
  position: absolute;
  left: 12px;
  top: 12px;
  font-weight: 900;
  color: rgba(107,242,120,0.90);
  font-size: 18px;
  animation: checkPulse 0.6s ease-out 1;
}

@keyframes withdrawSuccess {
  0% { transform: scale(1) translateY(0); opacity: 1; }
  50% { transform: scale(1.02) translateY(-2px); }
  100% { transform: scale(1) translateY(0); opacity: 1; }
}

@keyframes checkPulse {
  0% { transform: scale(0) rotate(-90deg); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1) rotate(0); opacity: 1; }
}

@keyframes balanceRefresh {
  0% { opacity: 0.7; transform: scale(0.98); }
  50% { transform: scale(1.02); }
  100% { opacity: 1; transform: scale(1); }
}

/* Wallet pulse animation - slower and more visible */
@keyframes walletPulse {
  0% { transform: scale(1) translateY(0); box-shadow: 0 0 0 rgba(0,200,255,0.5); }
  40% { transform: scale(1.04) translateY(-4px); box-shadow: 0 0 25px rgba(0,200,255,0.8); }
  100% { transform: scale(1) translateY(0); box-shadow: 0 0 0 rgba(0,200,255,0); }
}
.logEntry{ position: relative; }

/* Charts layout for statistics tab - Enhanced */
.chartRow{ 
  display:flex; 
  gap:20px; 
  align-items:stretch; 
  flex-wrap: wrap; 
  margin-top: 20px;
}
.chartCard {
  flex: 1;
  min-width: 300px;
  background: linear-gradient(135deg, rgba(0,230,255,0.03), rgba(59,224,201,0.015));
  padding: 24px;
  border-radius: 16px;
  border-left: 4px solid rgba(0,230,255,0.4);
  box-shadow:
    0 12px 48px rgba(0,0,0,0.2),
    0 0 1px rgba(0,230,255,0.15),
    inset 0 1px 0 rgba(255,255,255,0.08);
  transition: all 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
  backdrop-filter: blur(4px);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.chartCard::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 20% 50%, rgba(0,230,255,0.08), transparent 50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.chartCard:hover {
  border-left-color: rgba(0,230,255,0.8);
  border-color: rgba(0,230,255,0.2);
  box-shadow:
    0 18px 64px rgba(0,230,255,0.12),
    0 0 1px rgba(0,230,255,0.2),
    inset 0 1px 0 rgba(255,255,255,0.1);
  transform: translateY(-4px);
}

.chartCard:hover::before {
  opacity: 1;
}
.chartCard .cardHeader {
  font-weight: 700;
  margin-bottom: 18px;
  color: rgba(230,255,255,0.98);
  font-size: 15px;
  letter-spacing: -0.3px;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.8px;
  opacity: 0.95;
}
.chartCard canvas { width: 100% !important; height: 280px !important; display: block; }

/* ==================== SKELETON LOADING STATES ==================== */

.skeleton {
  background: linear-gradient(
    90deg,
    rgba(0,230,255,0.05) 0%,
    rgba(0,230,255,0.15) 50%,
    rgba(0,230,255,0.05) 100%
  );
  background-size: 200% 100%;
  animation: skeletonShimmer 2s infinite;
  border-radius: 8px;
  position: relative;
}

@keyframes skeletonShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-text {
  height: 16px;
  margin-bottom: 8px;
  border-radius: 4px;
}

.skeleton-avatar {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: inline-block;
}

.skeleton-card {
  height: 120px;
  border-radius: 12px;
  margin-bottom: 12px;
}

/* Loading spinner animation */
.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(0,230,255,0.2);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

/* ==================== ENHANCED NOTIFICATION STATES ==================== */

/* Success state with animated checkmark */
.success-check {
  width: 24px;
  height: 24px;
  border: 3px solid var(--color-success);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.success-check::after {
  content: '✓';
  color: var(--color-success);
  font-weight: 800;
  font-size: 16px;
  animation: checkPulse 0.6s ease-out;
}

@keyframes checkPulse {
  0% { 
    transform: scale(0) rotate(-90deg);
    opacity: 0;
  }
  50% { 
    transform: scale(1.2);
  }
  100% { 
    transform: scale(1) rotate(0);
    opacity: 1;
  }
}

/* Error state */
.error-cross {
  width: 24px;
  height: 24px;
  border: 3px solid var(--color-error);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  animation: errorShake 0.4s ease-out;
}

.error-cross::after {
  content: '×';
  color: var(--color-error);
  font-weight: 800;
  font-size: 20px;
}

@keyframes errorShake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

/* ==================== ADVANCED LEVEL 2 ANIMATIONS ==================== */

/* 1. CURSOR-FOLLOWING & MAGNETIC EFFECTS */
@keyframes magneticPull {
  0% { transform: translate(0, 0); }
  50% { transform: translate(var(--mx, 0px), var(--my, 0px)); }
  100% { transform: translate(0, 0); }
}

@keyframes parallaxShift {
  0%, 100% { transform: translateY(0) translateX(0); }
  50% { transform: translateY(-5px) translateX(5px); }
}

/* 2. PARTICLE & BACKGROUND EFFECTS */
@keyframes floatParticle {
  0% { transform: translateY(0) translateX(0) scale(1); opacity: 1; }
  50% { transform: translateY(-20px) translateX(10px) scale(0.8); opacity: 0.6; }
  100% { transform: translateY(-40px) translateX(20px) scale(0.5); opacity: 0; }
}

@keyframes orb {
  0% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(20px, -15px) scale(1.05); }
  50% { transform: translate(-10px, 20px) scale(1); }
  75% { transform: translate(-30px, -10px) scale(0.95); }
  100% { transform: translate(0, 0) scale(1); }
}

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

@keyframes mouseTrail {
  0% { opacity: 1; transform: translate(0, 0) scale(1); }
  100% { opacity: 0; transform: translate(var(--tx, 0), var(--ty, 0)) scale(0.3); }
}

/* 3. ADVANCED NOTIFICATIONS */
@keyframes toastSlide {
  from { opacity: 0; transform: translateX(400px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes toastStack {
  0% { transform: translateY(20px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

@keyframes toastDismiss {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(400px); }
}

@keyframes progressSlide {
  0% { width: 0%; }
  100% { width: 100%; }
}

@keyframes badgePopIn {
  0% { transform: scale(0) rotate(-180deg); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

@keyframes bubbleRise {
  0% { transform: translateY(0) scale(1); opacity: 1; }
  100% { transform: translateY(-100px) scale(0); opacity: 0; }
}

/* 4. FORM INTERACTIONS */
@keyframes validationCheck {
  0% { transform: scale(0) rotate(-90deg); }
  50% { transform: scale(1.2); }
  100% { transform: scale(1) rotate(0deg); }
}

@keyframes validationError {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

@keyframes strengthFill {
  from { width: 0%; }
  to { width: var(--strength-width, 100%); }
}

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

@keyframes autocompleteDrop {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes sectionCollapse {
  from { max-height: 500px; opacity: 1; }
  to { max-height: 0; opacity: 0; }
}

/* 5. SCROLLING & PAGE TRANSITIONS */
@keyframes scrollProgress {
  from { width: 0%; }
  to { width: var(--scroll-progress, 0%); }
}

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

@keyframes scrollTriggerSpin {
  from { transform: rotate(0deg) scale(0.9); opacity: 0; }
  to { transform: rotate(360deg) scale(1); opacity: 1; }
}

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

@keyframes parallaxScroll {
  0% { transform: translateY(0); }
  100% { transform: translateY(var(--parallax-offset, 20px)); }
}

/* 6. DATA VISUALIZATION */
@keyframes countUp {
  from { --value: 0; }
  to { --value: var(--target-value, 100); }
}

@keyframes chartBarDraw {
  0% { height: 0; opacity: 0; }
  100% { height: var(--bar-height, 100%); opacity: 1; }
}

@keyframes chartLineDraw {
  from { stroke-dashoffset: 1000; }
  to { stroke-dashoffset: 0; }
}

@keyframes dataPointPop {
  0% { transform: scale(0); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes progressRingFill {
  from { stroke-dashoffset: 283; }
  to { stroke-dashoffset: var(--ring-offset, 0); }
}

@keyframes gaugeNeedle {
  from { transform: rotate(0deg); }
  to { transform: rotate(var(--needle-angle, 45deg)); }
}

/* 7. GLASSMORPHISM 2.0 */
@keyframes glassShimmer {
  0%, 100% { background-position: -1000px center; }
  100% { background-position: 1000px center; }
}

@keyframes glassGlow {
  0%, 100% { box-shadow: inset 0 0 0 rgba(0,230,255,0.1); }
  50% { box-shadow: inset 0 0 20px rgba(0,230,255,0.3); }
}

@keyframes reflectionShift {
  0% { transform: translateX(-100%); opacity: 0; }
  50% { opacity: 0.3; }
  100% { transform: translateX(100%); opacity: 0; }
}

/* 8. DASHBOARD WIDGETS */
@keyframes resizeHandle {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}

@keyframes widgetShuffle {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(20px); }
}

@keyframes widgetCollapse {
  from { max-height: 400px; }
  to { max-height: 0; }
}

@keyframes widgetOpen {
  0% { transform: scale(0.8); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* 9. COLOR THEMING */
@keyframes themeTransition {
  from { filter: hue-rotate(0deg) saturate(1); }
  to { filter: hue-rotate(var(--hue-shift, 0deg)) saturate(var(--saturation, 1)); }
}

@keyframes accentPulseTheme {
  0%, 100% { --accent-glow: rgba(0,230,255,0.3); }
  50% { --accent-glow: rgba(0,230,255,0.6); }
}

@keyframes timeBasedTheme {
  from { background: var(--theme-day-color, #042735); }
  to { background: var(--theme-night-color, #001a2e); }
}

/* 10. TEXT ANIMATIONS */
@keyframes characterReveal {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes wordHighlight {
  0%, 100% { background-color: transparent; }
  50% { background-color: rgba(0,230,255,0.2); }
}

@keyframes typingEffect {
  from { width: 0; }
  to { width: 100%; }
}

@keyframes numberScramble {
  0% { opacity: 0.5; transform: translateY(10px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes letterSpaceExpand {
  from { letter-spacing: 0; }
  to { letter-spacing: 0.1em; }
}

/* 11. CHART INTERACTIONS */
@keyframes chartUpdate {
  0% { opacity: 0.5; }
  100% { opacity: 1; }
}

@keyframes legendToggle {
  0% { opacity: 1; }
  50% { opacity: 0.5; }
  100% { opacity: 1; }
}

@keyframes dataSeriesHighlight {
  0%, 100% { filter: brightness(1) saturate(1); }
  50% { filter: brightness(1.3) saturate(1.2); }
}

@keyframes chartZoom {
  from { transform: scale(0.8); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@keyframes exportFlash {
  0% { background-color: transparent; }
  50% { background-color: rgba(0,230,255,0.2); }
  100% { background-color: transparent; }
}

/* 12. ADVANCED LOADING */
@keyframes skeletonWave {
  0% { background-position: -1000px 0; }
  100% { background-position: 1000px 0; }
}

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

@keyframes previewBlur {
  0% { filter: blur(10px); opacity: 0.3; }
  100% { filter: blur(0px); opacity: 1; }
}

@keyframes timeRemaining {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* 13. HOVER CASCADE */
@keyframes childHoverStagger {
  0% { transform: translateY(10px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

@keyframes hoverBackgroundBlur {
  from { filter: blur(0px); opacity: 1; }
  to { filter: blur(5px); opacity: 0.5; }
}

@keyframes hoverColorShift {
  from { filter: hue-rotate(0deg); }
  to { filter: hue-rotate(10deg); }
}

@keyframes hoverShadowGrow {
  from { box-shadow: 0 0 0 rgba(0,230,255,0.2); }
  to { box-shadow: 0 0 30px rgba(0,230,255,0.5); }
}

@keyframes scaleCascade {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1.1); }
}

/* 14. GESTURE & SWIPE */
@keyframes swipeReveal {
  from { transform: translateX(0); }
  to { transform: translateX(80px); }
}

@keyframes swipeReturn {
  from { transform: translateX(80px); }
  to { transform: translateX(0); }
}

@keyframes dragGlow {
  0%, 100% { box-shadow: 0 0 0 rgba(0,230,255,0.2); }
  50% { box-shadow: 0 0 20px rgba(0,230,255,0.5); }
}

@keyframes dropZoneHighlight {
  0%, 100% { background-color: transparent; }
  50% { background-color: rgba(0,230,255,0.1); }
}

/* 15. STATUS INDICATORS */
@keyframes statusPulse {
  0% { box-shadow: 0 0 0 0 rgba(0,230,255,0.7); }
  50% { box-shadow: 0 0 0 10px rgba(0,230,255,0); }
}

@keyframes statusTimeline {
  from { transform: translateX(-100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes activityBar {
  0% { height: 2px; }
  50% { height: 8px; }
  100% { height: 2px; }
}

@keyframes signalStrength {
  0% { height: 0%; }
  100% { height: var(--signal-height, 80%); }
}

@keyframes statusColorFade {
  from { color: #14f195; }
  to { color: #00e6ff; }
}

/* 16. SOUND INDICATOR ANIMATIONS */
@keyframes soundWave {
  0%, 100% { height: 5px; }
  50% { height: 20px; }
}

@keyframes vibrationPulse {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-2px); }
  75% { transform: translateX(2px); }
}

/* 17. MENU ANIMATIONS */
@keyframes menuSlideLeft {
  from { transform: translateX(-100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

@keyframes menuSlideRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

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

@keyframes nestedMenuSlide {
  from { transform: scale(0.95) translateX(-10px); opacity: 0; }
  to { transform: scale(1) translateX(0); opacity: 1; }
}

@keyframes hamburgerX {
  from { transform: rotate(0deg); }
  to { transform: rotate(45deg); }
}

@keyframes menuHoverSlide {
  from { background-position: 0% center; }
  to { background-position: 100% center; }
}

/* 18. MODAL ANIMATIONS */
@keyframes modalScaleIn {
  from { transform: scale(0.9) translateY(20px); opacity: 0; }
  to { transform: scale(1) translateY(0); opacity: 1; }
}

@keyframes backdropBlur {
  from { filter: blur(0px); background-color: rgba(0,0,0,0); }
  to { filter: blur(5px); background-color: rgba(0,0,0,0.4); }
}

@keyframes modalStackOffset {
  0% { transform: translateX(0) translateY(0); }
  100% { transform: translateX(20px) translateY(20px); }
}

@keyframes modalDismiss {
  from { transform: scale(1) translateY(0); opacity: 1; }
  to { transform: scale(0.8) translateY(20px); opacity: 0; }
}

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

/* 19. SHADOW & DEPTH */
@keyframes shadowExpand {
  0% { box-shadow: 0 0 10px rgba(0,230,255,0.1); }
  100% { box-shadow: 0 0 30px rgba(0,230,255,0.3); }
}

@keyframes ambientOcclusion {
  0%, 100% { box-shadow: 
    0 2px 4px rgba(0,0,0,0.2),
    0 4px 8px rgba(0,0,0,0.1); }
  50% { box-shadow: 
    0 4px 8px rgba(0,0,0,0.3),
    0 8px 16px rgba(0,0,0,0.15); }
}

/* 20. GAMIFICATION */
@keyframes confetti {
  0% { transform: translateY(0) translateX(0) rotate(0deg); opacity: 1; }
  100% { transform: translateY(-100px) translateX(var(--x, 20px)) rotate(360deg); opacity: 0; }
}

@keyframes achievementUnlock {
  0% { transform: scale(0) rotate(-180deg); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

@keyframes levelUpFlash {
  0% { background-color: transparent; }
  50% { background-color: rgba(255,215,0,0.3); }
  100% { background-color: transparent; }
}

@keyframes starFill {
  from { clip-path: polygon(0 0, 0% 100%, 0 100%); opacity: 0; }
  to { clip-path: polygon(0 0, 100% 100%, 100% 100%); opacity: 1; }
}

@keyframes badgeUnlock {
  0% { transform: translateY(-50px) scale(0); opacity: 0; }
  50% { transform: translateY(-10px) scale(1.1); }
  100% { transform: translateY(0) scale(1); opacity: 1; }
}

/* 21. FILTERING & SEARCH */
@keyframes resultsStagger {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes filterBadgeAppear {
  0% { transform: scale(0) rotate(-180deg); opacity: 0; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

@keyframes filterBadgeFly {
  from { opacity: 1; transform: translateX(0) scale(1); }
  to { opacity: 0; transform: translateX(50px) scale(0); }
}

@keyframes searchInputGlow {
  0%, 100% { box-shadow: 0 0 0 rgba(0,230,255,0.3); }
  50% { box-shadow: 0 0 20px rgba(0,230,255,0.6); }
}

@keyframes resultCountPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

/* 22. TIMELINE */
@keyframes timelineEntrySlide {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes timelineConnectorDraw {
  from { stroke-dashoffset: 100; }
  to { stroke-dashoffset: 0; }
}

@keyframes timelineDatePop {
  0% { transform: scale(0); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

@keyframes milestonePulse {
  0%, 100% { box-shadow: 0 0 0 rgba(0,230,255,0.3); }
  50% { box-shadow: 0 0 20px rgba(0,230,255,0.6); }
}

@keyframes timelineProgressFill {
  from { width: 0%; }
  to { width: 100%; }
}

/* 23. CARD EXPANSIONS */
@keyframes cardExpand {
  from { max-height: 200px; }
  to { max-height: 500px; }
}

@keyframes cardFlip {
  0% { transform: rotateY(0deg); }
  100% { transform: rotateY(180deg); }
}

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

@keyframes cardMagnify {
  from { transform: scale(1); }
  to { transform: scale(1.05); }
}

/* 24. ACCESSIBILITY */
@keyframes highContrastTransition {
  from { filter: invert(0) contrast(1); }
  to { filter: invert(0) contrast(1.5); }
}

@keyframes focusRingPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(0,230,255,0.5); }
  50% { box-shadow: 0 0 0 6px rgba(0,230,255,0.3); }
}

@keyframes fontSizeTransition {
  from { font-size: 14px; line-height: 1.4; }
  to { font-size: 18px; line-height: 1.6; }
}

/* 25. ICON ANIMATIONS */
@keyframes iconSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes iconStrokeDraw {
  from { stroke-dashoffset: 1000; }
  to { stroke-dashoffset: 0; }
}

@keyframes iconFill {
  from { fill: transparent; }
  to { fill: currentColor; }
}

@keyframes iconCrossFade {
  0% { opacity: 1; transform: scale(1); }
  50% { opacity: 0; transform: scale(0.8); }
  100% { opacity: 1; transform: scale(1); }
}

@keyframes iconGlowPulse {
  0%, 100% { filter: drop-shadow(0 0 0px currentColor); }
  50% { filter: drop-shadow(0 0 10px currentColor); }
}
.authWrap{
  position:fixed; inset:0; display:flex; align-items:center; justify-content:center; z-index:10;
  background: linear-gradient(135deg, rgba(0,12,26,0.95) 0%, rgba(0,18,35,0.98) 50%, rgba(0,12,26,0.95) 100%);
  padding:24px;
  overflow-y:auto;
}

.authContainer{
  position:relative;
  width: 100%;
  max-width:520px;
}

/* Animated background glows */
.authBgGlow{
  position:absolute;
  border-radius:50%;
  filter:blur(80px);
  opacity:0.15;
  pointer-events:none;
  animation:glow 8s ease-in-out infinite;
}
.authBgGlow1{
  width:300px;
  height:300px;
  background:radial-gradient(circle, #00e6ff 0%, transparent 70%);
  top:-100px;
  left:-80px;
  animation-delay:0s;
}
.authBgGlow2{
  width:250px;
  height:250px;
  background:radial-gradient(circle, #3be0c9 0%, transparent 70%);
  bottom:-50px;
  right:-100px;
  animation-delay:4s;
}
@keyframes glow{
  0%, 100%{ transform:translate(0, 0); opacity:0.15; }
  50%{ transform:translate(20px, -20px); opacity:0.25; }
}

.authCard{
  position:relative;
  z-index:1;
  border-radius:20px;
  padding:48px;
  background: linear-gradient(180deg, rgba(4,39,53,0.7) 0%, rgba(0,18,35,0.5) 100%);
  backdrop-filter:blur(20px);
  box-shadow: 0 25px 50px rgba(0,0,0,0.4), 
              0 0 1px rgba(0,230,255,0.5) inset,
              0 8px 32px rgba(0,230,255,0.08);
  border:1px solid rgba(0,230,255,0.15);
  color:var(--text);
}

.authBrand{
  display:flex;
  align-items:center;
  gap:16px;
  margin-bottom:32px;
  padding-bottom:24px;
  border-bottom:1px solid rgba(0,230,255,0.1);
}

.authLogo{
  width:56px;
  height:56px;
  border-radius:14px;
  object-fit:cover;
  box-shadow:0 8px 24px rgba(0,230,255,0.15);
}

.authBrandTitle{
  font-size:28px;
  font-weight:800;
  letter-spacing:-0.5px;
  margin:0;
  color:#ffffff;
}

.authBrandSubtitle{
  font-size:12px;
  color:rgba(230,255,255,0.6);
  margin:4px 0 0 0;
  letter-spacing:0.3px;
  text-transform:uppercase;
}

.authTitleSection{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  margin-bottom:32px;
  gap:20px;
}

.authTitle{
  font-size:24px;
  font-weight:700;
  margin:0 0 6px 0;
  letter-spacing:-0.3px;
}

.authSubtitle{
  font-size:13px;
  color:rgba(230,255,255,0.6);
  margin:0;
}

.authToggleBtn{
  background:linear-gradient(135deg, rgba(0,230,255,0.12), rgba(59,224,201,0.08));
  border:1px solid rgba(0,230,255,0.25);
  color:var(--muted);
  padding:14px 24px;
  border-radius:12px;
  cursor:pointer;
  font-weight:700;
  font-size:13px;
  display:flex;
  align-items:center;
  gap:10px;
  transition:all 0.3s ease;
  white-space:nowrap;
}

.authToggleBtn:hover{
  background:linear-gradient(135deg, rgba(0,230,255,0.2), rgba(59,224,201,0.15));
  border-color:rgba(0,230,255,0.4);
  color:var(--accent);
  box-shadow:0 8px 20px rgba(0,230,255,0.12);
}

.authToggleArrow{
  display:inline-block;
  transition:transform 0.3s ease;
  font-size:14px;
}

.authToggleBtn:hover .authToggleArrow{
  transform:translateX(4px);
}

.authForm{
  display:flex;
  flex-direction:column;
  gap:18px;
}

.formLabel{
  font-size:11px;
  font-weight:700;
  color:rgba(230,255,255,0.8);
  text-transform:uppercase;
  letter-spacing:0.6px;
  display:block;
  margin-bottom:8px;
}

.inputWrapper{
  position:relative;
  display:flex;
  align-items:center;
}

.authInput{
  width:100%;
  padding:12px 40px 12px 16px !important;
  font-size:14px;
  transition:all 0.3s ease;
  background:linear-gradient(180deg, rgba(0,230,255,0.04), rgba(59,224,201,0.02)) !important;
  border:1px solid rgba(0,230,255,0.2) !important;
  color:var(--text) !important;
}

.authInput:focus{
  background:linear-gradient(180deg, rgba(0,230,255,0.08), rgba(59,224,201,0.04)) !important;
  border-color:rgba(0,230,255,0.4) !important;
  box-shadow:0 0 20px rgba(0,230,255,0.15), 0 0 0 3px rgba(0,230,255,0.08) !important;
  outline:none;
}

.authInput::placeholder{
  color:rgba(230,255,255,0.4);
}

.inputIcon{
  position:absolute;
  right:12px;
  width:18px;
  height:18px;
  color:rgba(0,230,255,0.6);
  pointer-events:none;
  stroke-linecap:round;
  stroke-linejoin:round;
  flex-shrink:0;
}

.walletAddressesSection{
  margin-top:18px;
  padding-top:18px;
  border-top:1px solid rgba(0,230,255,0.1);
}

.walletToggleBtn{
  width:100%;
  padding:12px 16px;
  background:linear-gradient(135deg, rgba(0,230,255,0.06), rgba(59,224,201,0.03));
  border:1px solid rgba(0,230,255,0.15);
  color:rgba(230,255,255,0.8);
  border-radius:12px;
  cursor:pointer;
  font-size:13px;
  font-weight:600;
  display:flex;
  justify-content:space-between;
  align-items:center;
  transition:all 0.3s ease;
  letter-spacing:0.3px;
}

.walletToggleBtn:hover{
  background:linear-gradient(135deg, rgba(0,230,255,0.12), rgba(59,224,201,0.06));
  border-color:rgba(0,230,255,0.25);
}

.walletToggleIcon{
  display:inline-block;
  transition:transform 0.3s ease;
  font-size:12px;
}

.walletToggleBtn[aria-expanded="true"] .walletToggleIcon{
  transform:rotate(180deg);
}

#walletFields{
  display:none;
  margin-top:12px;
}

.authSubmitBtn{
  padding:14px 20px;
  margin-top:8px;
  background:linear-gradient(135deg, #00e6ff 0%, #3be0c9 100%);
  border:none;
  color:#001829;
  font-weight:700;
  font-size:14px;
  border-radius:12px;
  cursor:pointer;
  transition:all 0.3s ease;
  box-shadow:0 8px 24px rgba(0,230,255,0.25);
  letter-spacing:0.5px;
  text-transform:uppercase;
}

.authSubmitBtn:hover{
  transform:translateY(-2px);
  box-shadow:0 12px 32px rgba(0,230,255,0.35);
}

.authSubmitBtn:active{
  transform:translateY(0);
}

.authMessage{
  font-size:13px;
  text-align:center;
  padding:10px;
  border-radius:8px;
  min-height:24px;
  margin-top:8px;
}

.authMessage:empty{
  display:none;
}

.authMessage.error{
  color:#ff8a8a;
  background:rgba(255,100,100,0.1);
  border:1px solid rgba(255,100,100,0.2);
}

.authMessage.success{
  color:#90ee90;
  background:rgba(144,238,144,0.1);
  border:1px solid rgba(144,238,144,0.2);
}

.authFooter{
  text-align:center;
  font-size:11px;
  color:rgba(230,255,255,0.5);
  margin-top:20px;
  padding-top:20px;
  border-top:1px solid rgba(0,230,255,0.08);
}

/* form */
.formRow{ display:flex; flex-direction:column; gap:6px; margin-top:6px; }
.input{
  padding:10px 12px; 
  border-radius:10px; 
  background: rgba(255,255,255,0.01);
  border:1px solid rgba(255,255,255,0.04); 
  color:var(--text); 
  outline:none;
  transition: all 0.2s ease;
  font-size: 14px;
}

.input:focus {
  border-color: rgba(0,230,255,0.3);
  box-shadow: 0 0 0 4px rgba(0,230,255,0.08), inset 0 1px 2px rgba(0,230,255,0.05);
  background: rgba(0,230,255,0.02);
}

.input::placeholder { 
  color: rgba(230,255,255,0.45); 
}

.formLabel {
  font-size: 11px;
  font-weight: 700;
  color: rgba(230,255,255,0.8);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  display: block;
  margin-bottom: 8px;
  transition: all 0.2s ease;
}

.formLabel.active {
  color: var(--accent);
  text-shadow: 0 0 8px rgba(0,230,255,0.2);
}

/* Make selects visually match inputs and the ocean theme */
select.input{
  -webkit-appearance: none; -moz-appearance: none; appearance: none;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
  border: 1px solid rgba(0,230,255,0.10);
  color: var(--text);
  padding:10px 14px; padding-right:40px; position:relative;
  background-image: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01)),
                    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23E6F7FB' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat; background-position: right 12px center;
  box-shadow: 0 6px 20px rgba(0,200,220,0.03);
}

/* Disabled / inert compile button appearance */
.btnPrimary.inert{
  opacity: 0.65; cursor: not-allowed; box-shadow:none; transform:none;
}

/* ==================== CARD ACCENT COLORS ==================== */

.card-success { 
  border-left-color: var(--color-success) !important;
}
.card-success:hover {
  box-shadow: inset 0 2px 12px rgba(255,255,255,0.04), 0 26px 60px rgba(20,241,149,0.15) !important;
}

.card-warning { 
  border-left-color: var(--color-warning) !important;
}
.card-warning:hover {
  box-shadow: inset 0 2px 12px rgba(255,255,255,0.04), 0 26px 60px rgba(255,210,127,0.15) !important;
}

.card-error { 
  border-left-color: var(--color-error) !important;
}
.card-error:hover {
  box-shadow: inset 0 2px 12px rgba(255,255,255,0.04), 0 26px 60px rgba(255,126,143,0.15) !important;
}

.card-info { 
  border-left-color: var(--color-info) !important;
}
.card-info:hover {
  box-shadow: inset 0 2px 12px rgba(255,255,255,0.04), 0 26px 60px rgba(126,200,255,0.15) !important;
}

/* ==================== TEXT & TYPOGRAPHY ENHANCEMENTS ==================== */

/* Text gradient effect for headlines */
.text-gradient {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 800;
}

/* Glowing text effect */
.text-glow {
  color: var(--accent);
  text-shadow: 0 0 20px rgba(0,230,255,0.5);
  animation: textGlow 2s ease-in-out infinite;
}

@keyframes textGlow {
  0%, 100% { 
    text-shadow: 0 0 20px rgba(0,230,255,0.3);
  }
  50% { 
    text-shadow: 0 0 30px rgba(0,230,255,0.6);
  }
}

/* ==================== TRANSITION UTILITIES ==================== */

.transition-smooth {
  transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.transition-fast {
  transition: all 0.15s ease;
}

.transition-slow {
  transition: all 0.5s ease;
}

/* ==================== ELEVATION UTILITIES ==================== */

.elevated-sm {
  box-shadow: var(--shadow-md);
}

.elevated-md {
  box-shadow: var(--shadow-lg);
}

.elevated-lg {
  box-shadow: var(--shadow-xl);
}

.elevated-2xl {
  box-shadow: var(--shadow-2xl);
}

.elevated-hover {
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.elevated-hover:hover {
  box-shadow: var(--shadow-2xl), var(--shadow-hover);
  transform: translateY(-4px);
}
.walletList{ display:flex; flex-direction:column; gap:10px; margin-top:8px; }
.walletRow{ display:flex; align-items:center; gap:12px; padding:10px 12px; border-radius:10px; background: linear-gradient(90deg, rgba(0,230,255,0.03), rgba(59,224,201,0.015)); border:1px solid rgba(0,230,255,0.06); }
.walletLabel{ font-weight:800; min-width:90px; color:var(--text); }
.walletValue{ color: rgba(230,255,255,0.9); word-break:break-all; }
.walletEmpty{ color: rgba(230,255,255,0.5); font-style:italic; }

/* Editable wallet rows */
.walletEditRow{ display:flex; align-items:center; gap:12px; padding:8px 0; }
.walletEditRow .walletLabel{ min-width:90px; }
.walletInput{ flex:1; padding:10px 12px; border-radius:10px; background: rgba(255,255,255,0.01); border:1px solid rgba(0,230,255,0.10); color:var(--text); outline:none; font-size:13px; font-family: monospace; }
.walletInput:focus{ border-color: rgba(0,230,255,0.30); box-shadow: 0 0 16px rgba(0,230,255,0.06); }
.walletInput::placeholder{ color: rgba(230,255,255,0.35); }
.input::placeholder{ color: rgba(230,255,255,0.45); }
.btnPrimary {
  padding: 12px 20px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #012;
  font-weight: 700;
  border: 1px solid rgba(0, 230, 255, 0.3);
  cursor: pointer;
  box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  font-size: 14px;
  letter-spacing: 0.3px;
  position: relative;
  overflow: hidden;
}

.btnPrimary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}

.btnPrimary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl), var(--shadow-hover), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.btnPrimary:hover::before {
  left: 100%;
}

.btnPrimary:active {
  transform: translateY(0);
  box-shadow: var(--shadow-md);
}
.compileCard{ 
  display:flex; 
  gap:24px; 
  align-items:flex-start; 
  padding:24px; 
  border-radius:18px; 
  margin-top:16px; 
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01)); 
  border:1px solid rgba(255,255,255,0.04); 
  box-shadow: 0 20px 60px rgba(0,0,0,0.1), 0 2px 6px rgba(0,210,220,0.04); 
}
.compileBtn {
  padding: 12px 26px;
  font-size: 15px;
  border-radius: 12px;
  min-width: 140px;
  height: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.26s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.26s ease;
  letter-spacing: 0.3px;
  box-shadow: 0 8px 22px rgba(0,210,220,0.10);
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #012;
  border: 1px solid rgba(0, 230, 255, 0.25);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.compileBtn::before {
  content: '';
  position: absolute;
  inset: 0;
  margin: 2px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.00));
  pointer-events: none;
  mix-blend-mode: overlay;
  opacity: 0.9;
}

.compileBtn::after {
  content: '';
  position: absolute;
  left: -6px;
  right: -6px;
  top: -6px;
  bottom: -6px;
  border-radius: 14px;
  background: radial-gradient(circle at 10% 10%, rgba(0,230,255,0.12), transparent 20%);
  filter: blur(8px);
  opacity: 0.85;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.compileBtn:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 26px 70px rgba(0,200,220,0.22), 0 6px 20px rgba(0,0,0,0.45);
}

.compileBtn:hover::after {
  opacity: 1;
}

.compileBtn:active {
  transform: translateY(-2px) scale(0.995);
  box-shadow: 0 12px 40px rgba(0,200,220,0.14);
}

.compileBtn .icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:22px;
  height:22px;
  font-size:18px;
  transition: transform 0.32s cubic-bezier(0.16, 0.9, 0.3, 1);
}

.compileBtn:hover .icon{
  transform: translateY(-2px) scale(1.15);
}

.compileBtn .label{
  display:inline-block;
  font-weight:700;
  font-size:15px;
}

/* Nudge label down slightly so icon and text appear visually centered */
.compileBtn .label{ transform: translateY(2px); }

/* Improve compile button focus/active states and subtle glossy sheen */
.compileBtn:focus{ outline: none; box-shadow: 0 6px 22px rgba(0,200,220,0.16); }
.compileBtn{ background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.compileBtn::after{ content: ''; position: absolute; left:0; right:0; top:0; height:40%; background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.02)); border-top-left-radius:12px; border-top-right-radius:12px; pointer-events:none; opacity:0.6; }

/* When launching, also give the label a soft lift and ease the icon animation */
.compileBtn.launch .label{ transform: translateY(0); transition: transform 460ms cubic-bezier(0.16,0.9,0.3,1); }

@keyframes launchIcon {
  0% { transform: translateY(0) rotate(0deg) scale(1); }
  45% { transform: translateY(-6px) rotate(-6deg) scale(1.06); }
  100% { transform: translateY(-10px) rotate(-10deg) scale(1.02); }
}

.compileBtn.launch .icon{ animation: launchIcon 0.7s cubic-bezier(0.16,0.9,0.3,1); }

/* Stronger Generate button design */
.compileBtn{
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(0,230,255,0.98), rgba(59,224,201,0.95));
  color: #012;
  border: 1px solid rgba(255,255,255,0.06);
  box-shadow: 0 10px 40px rgba(0,200,220,0.18), 0 2px 10px rgba(0,0,0,0.35);
}
.compileBtn::before{
  content: '';
  position: absolute;
  inset: 0;
  margin: 2px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(255,255,255,0.06), rgba(255,255,255,0.00));
  pointer-events: none;
  mix-blend-mode: overlay;
  opacity: 0.9;
}
.compileBtn::after{ /* subtle outer glow */
  content: '';
  position: absolute;
  left: -6px; right: -6px; top: -6px; bottom: -6px;
  border-radius: 14px;
  background: radial-gradient(circle at 10% 10%, rgba(0,230,255,0.12), transparent 20%);
  filter: blur(8px);
  opacity: 0.85;
  pointer-events: none;
}
.compileBtn:hover{ transform: translateY(-6px) scale(1.02); box-shadow: 0 26px 70px rgba(0,200,220,0.22), 0 6px 20px rgba(0,0,0,0.45); }
.compileBtn:active{ transform: translateY(-2px) scale(0.995); box-shadow: 0 12px 40px rgba(0,200,220,0.14); }

/* ripple effect element (used by JS) */
.ripple{ position:absolute; border-radius:50%; transform: translate(-50%,-50%) scale(0); pointer-events:none; background: radial-gradient(circle, rgba(255,255,255,0.85) 0%, rgba(255,255,255,0.2) 30%, transparent 60%); animation: ripple 650ms cubic-bezier(.2,.9,.2,1) forwards; opacity:0.95; }

/* Tweak compile card alignment specifically so the action column centers vertically */
#compileCard{ align-items: center; }

/* Ensure form rows take full width inside the card */
.compileCard .formRow{ width:100%; }

/* Center chart headers and make them visually aligned */
.chartCard .cardHeader{
  text-align: center;
  width: 100%;
  margin-bottom: 12px;
}

/* Prefer dark color-scheme inside compileCard so select dropdowns/scrollbars match UI */
.compileCard select{
  color-scheme: dark;
}

/* Custom select component styles for compileCard */
.custom-select-wrapper{ position: relative; display: inline-block; width: 100%; max-width:420px; }
.custom-select-display{ display:flex; align-items:center; justify-content:space-between; width:100%; padding:12px 14px; border-radius:8px; background: linear-gradient(180deg, rgba(4,39,53,0.6), rgba(0,18,35,0.6)); color:var(--text); border:1px solid rgba(255,255,255,0.03); cursor:pointer; }
.custom-select-display:focus{ outline:2px solid rgba(0,230,255,0.12); }
.custom-select-list{ position:absolute; left:0; right:0; top:calc(100% + 8px); max-height:260px; overflow:auto; background:linear-gradient(180deg, rgba(4,39,53,0.95), rgba(0,18,35,0.95)); border-radius:8px; border:1px solid rgba(255,255,255,0.04); box-shadow: 0 12px 40px rgba(0,0,0,0.6); padding:6px; opacity:0; transform:translateY(-6px); transition:opacity .18s ease, transform .18s ease; z-index:40; visibility:hidden; }
.custom-select-list.open{ opacity:1; transform:translateY(0); visibility:visible; }
.custom-select-item{ padding:8px 12px; margin:2px 0; border-radius:6px; color:var(--text); cursor:pointer; }
.custom-select-item:hover{ background:rgba(255,255,255,0.03); }
.custom-select-item.selected{ background: linear-gradient(90deg, rgba(0,230,255,0.06), rgba(59,224,201,0.04)); color:#dffcff; font-weight:600; }
.custom-select-item.disabled{ opacity:0.35; cursor:not-allowed; }

/* custom scrollbar for option list */
.custom-select-list::-webkit-scrollbar{ width:12px; }
.custom-select-list::-webkit-scrollbar-track{ background: transparent; }
.custom-select-list::-webkit-scrollbar-thumb{ background: linear-gradient(180deg, rgba(0,230,255,0.12), rgba(59,224,201,0.06)); border-radius:8px; border:3px solid transparent; background-clip: padding-box; }
/* Firefox scrollbar */
.custom-select-list{ scrollbar-width: thin; scrollbar-color: rgba(0,230,255,0.12) transparent; }

/* Rank badges and progress UI */
.rankBadge{ display:inline-block; width:14px; height:14px; border-radius:50%; box-shadow:0 2px 8px rgba(0,0,0,0.4) inset; vertical-align:middle; }
.rankBadge.small{ width:12px; height:12px; margin-left:6px; }
.rank-bronze{ background: linear-gradient(180deg,#b87333,#8b4b2b); border:1px solid rgba(0,0,0,0.12); }
.rank-silver{ background: linear-gradient(180deg,#c0c0c0,#9a9a9a); border:1px solid rgba(0,0,0,0.12); }
.rank-gold{ background: linear-gradient(180deg,#ffd700,#cfa200); border:1px solid rgba(0,0,0,0.12); }
.rank-diamond{ background: linear-gradient(180deg,#bfe9ff,#7fd6ff); border:1px solid rgba(0,0,0,0.12); }
.rank-elite{ background: linear-gradient(180deg,#ff7ef0,#c14dbd); border:1px solid rgba(0,0,0,0.12); }

.rankProgressHeader{ font-weight:700; color:var(--text); display:flex; align-items:center; gap:8px; }
.rankProgressBar{ width:100%; height:12px; background:linear-gradient(180deg, rgba(255,255,255,0.03), rgba(0,0,0,0.06)); border-radius:10px; overflow:hidden; border:1px solid rgba(255,255,255,0.03); margin-top:8px; }
.rankProgressFill{ height:100%; background:linear-gradient(90deg, rgba(0,230,255,0.9), rgba(59,224,201,0.7)); width:0%; transition:width 800ms cubic-bezier(.2,.9,.2,1); }

/* Rank up floating animation */
.rankUpFloating{ position:fixed; left:50%; top:20%; transform:translateX(-50%) translateY(-10px) scale(0.9); z-index:9999; padding:14px 20px; border-radius:16px; background:linear-gradient(90deg, rgba(0,230,255,0.12), rgba(59,224,201,0.08)); color:#eaffff; box-shadow:0 20px 60px rgba(0,0,0,0.6); opacity:0; transition:all 420ms ease; pointer-events:none; }
.rankUpFloating.visible{ transform:translateX(-50%) translateY(0) scale(1); opacity:1; }
.rankUpFloating .rankUpInner{ font-weight:800; font-size:16px; display:flex; align-items:center; gap:10px; }
.rankUpFloating.rank-bronze{ border:2px solid rgba(184,115,51,0.14); }
.rankUpFloating.rank-silver{ border:2px solid rgba(192,192,192,0.14); }
.rankUpFloating.rank-gold{ border:2px solid rgba(255,215,0,0.14); }
.rankUpFloating.rank-diamond{ border:2px solid rgba(191,233,255,0.14); }
.rankUpFloating.rank-elite{ border:2px solid rgba(255,126,240,0.14); }

/* small sparkle effect inside floating badge (simple) */
.rankUpFloating .sparkles{ width:12px; height:12px; border-radius:50%; background:radial-gradient(circle, rgba(255,255,255,0.9) 0%, rgba(255,255,255,0.2) 40%, transparent 70%); box-shadow:0 0 18px rgba(255,255,255,0.08); }

/* Rank component interactive styles */
.rankComponent{ display:flex; flex-direction:column; gap:8px; padding:12px; background:linear-gradient(180deg, rgba(4,39,53,0.6), rgba(0,18,35,0.6)); border-radius:10px; border:1px solid rgba(255,255,255,0.03); }
.rankComponent .rankTop{ display:flex; align-items:center; justify-content:space-between; gap:12px; }
.rankComponent .rankInfo{ display:flex; align-items:center; gap:8px; }
.rankComponent .rankLabel{ font-weight:700; color:var(--text); }
.rankComponent .rankPercent{ font-weight:800; color:#00e6ff; }
.rankComponent .rankProgressBarInteractive{ width:100%; height:16px; background:linear-gradient(180deg, rgba(0,230,255,0.08), rgba(59,224,201,0.04)); border-radius:10px; overflow:hidden; border:1px solid rgba(0,230,255,0.2); cursor:pointer; transition:all 0.3s ease; position:relative; box-shadow:inset 0 2px 4px rgba(0,0,0,0.1), 0 0 12px rgba(0,230,255,0.1); }
.rankComponent .rankProgressBarInteractive:hover{ border-color:rgba(0,230,255,0.35); box-shadow:inset 0 2px 4px rgba(0,0,0,0.1), 0 0 20px rgba(0,230,255,0.2); }
.rankComponent .rankProgressFillInteractive{ height:100%; background:linear-gradient(90deg, #00e6ff, #3be0c9); width:0%; transition:width 900ms cubic-bezier(.2,.9,.2,1), transform 450ms cubic-bezier(.2,.9,.2,1); border-radius:8px; box-shadow:0 6px 28px rgba(0,230,255,0.38), inset 0 1px 2px rgba(255,255,255,0.3); position:relative; transform-origin:left center; }
.rankComponent .rankProgressFillInteractive.grow{ animation: fillPulse 1.2s cubic-bezier(.2,.9,.2,1) forwards; }
.rankComponent .rankProgressFillInteractive::after{ content:''; position:absolute; top:0; left:0; right:0; bottom:0; background:linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent); animation:progressShimmer 2s infinite; border-radius:8px; }
@keyframes progressShimmer{ 0%{ transform:translateX(-100%); } 100%{ transform:translateX(100%); } }
@keyframes fillPulse{
  0%{ transform: scaleX(0.985); filter: blur(0px); }
  35%{ transform: scaleX(1.01); filter: blur(0.2px); }
  70%{ transform: scaleX(0.995); filter: blur(0px); }
  100%{ transform: scaleX(1); filter: blur(0px); }
}

/* Home rank section depth */
/* Home rank section wrapper (outer) */
#homeRankSection{ background:transparent; border-radius:16px; border:1px solid rgba(255,255,255,0.02); box-shadow:0 10px 30px rgba(0,0,0,0.55); }
#homeRankSection::before{ content:''; position:absolute; right:-80px; top:-40px; width:320px; height:320px; background:radial-gradient(circle at 30% 30%, rgba(207,242,247,0.06), transparent 40%); transform:rotate(15deg); pointer-events:none; }

/* Inner dark panel to match stat cards */
#homeRankSection .rankInner{
  padding:18px;
  background:linear-gradient(180deg, rgba(4,39,53,0.62), rgba(0,18,35,0.62));
  border-radius:12px;
  border:1px solid rgba(255,255,255,0.03);
  box-shadow:inset 0 2px 8px rgba(255,255,255,0.02), 0 8px 28px rgba(0,0,0,0.6);
  transition: transform 200ms ease, box-shadow 200ms ease;
  transform: translateY(-6px);
}
#homeRankSection .rankInner .rankComponent{ background:transparent; border:none; padding:0; gap:12px; }

/* Gloss overlay for statistics tiles to match panel sheen */
/* Base stat card style to match rank panel */
.statCard{ 
  position:relative; 
  overflow:hidden; 
  padding:18px; 
  background:linear-gradient(180deg, rgba(4,39,53,0.62), rgba(0,18,35,0.62)); 
  border-radius:12px; 
  border-left: 3px solid rgba(0,230,255,0.3);
  box-shadow:inset 0 2px 8px rgba(255,255,255,0.02), 0 8px 28px rgba(0,0,0,0.6); 
  transition: all 260ms cubic-bezier(0.4,0,0.2,1); 
}

.statCard:hover{ 
  border-left-color: rgba(0,230,255,0.8);
  transform: translateY(-6px) rotate(-0.6deg); 
  box-shadow: inset 0 2px 12px rgba(255,255,255,0.04), 0 26px 60px rgba(0,0,0,0.65); 
  background: linear-gradient(180deg, rgba(4,39,53,0.75), rgba(0,18,35,0.70));
}

.statCard::before{ 
  content: ''; 
  position: absolute; 
  inset: -2px; 
  border-radius:12px; 
  padding:2px; 
  background: linear-gradient(90deg, rgba(0,230,255,0.04), rgba(59,224,201,0.03)); 
  mix-blend-mode: screen; 
  opacity:0.7; 
  pointer-events:none; 
  transform: scale(0.995); 
}

.statCard .small{ color: rgba(200,230,240,0.6); }
.statCard .value{ 
  font-weight:800; 
  color:#00e6ff;
  animation: countBounce 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.statCard::after{
  content: '';
  position: absolute;
  left: -20%;
  top: -30%;
  width: 140%;
  height: 60%;
  background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.00));
  transform: skewY(-6deg);
  opacity: 0.6;
  pointer-events: none;
  mix-blend-mode: overlay;
  transition: opacity 300ms ease, transform 300ms ease;
  border-radius: 12px;
}

.statCard:hover::after{ 
  opacity: 0.9; 
  transform: skewY(-4deg) translateY(-4px); 
}

/* Tooltip for rank progress */
.rankTooltip{
  position:fixed; /* use fixed so it's always visible over panels */
  z-index: 9999;
  background: rgba(2,18,28,0.95);
  color: #cff2f7;
  padding:6px 10px;
  border-radius:6px;
  font-size:13px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.02);
  pointer-events: none;
  opacity: 0;
  transform: translateY(-8px) scale(0.98);
  transition: opacity 160ms ease, transform 180ms ease;
}
.rankTooltip.visible{ opacity:1; transform: translateY(0) scale(1); }
.media-adjust-placeholder{}

@media (max-width: 720px){
  /* Reduce the lift on small screens to avoid layout crowding */
  #homeRankSection .rankInner{ transform: translateY(-2px); }
}

/* Logs list UI improvements */
.logsList{ display:flex; flex-direction:column; gap:8px; }
.logsList .logRow{ display:flex; gap:12px; align-items:flex-start; padding:10px 12px; border-radius:10px; background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.006)); border:1px solid rgba(255,255,255,0.03); font-size:13px; }
.logsList .logRow:hover{ box-shadow: 0 10px 30px rgba(0,0,0,0.45); transform: translateY(-4px); }
.logsList .logRow .time{ width:120px; color: rgba(180,210,220,0.7); font-size:12px; flex:0 0 120px; }
.logsList .logRow .msg{ color: rgba(220,245,250,0.95); font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, 'Roboto Mono', monospace; white-space:pre-wrap; word-break:break-word; }

/* ==================== ADVANCED UTILITY CLASSES ==================== */

/* 1. CURSOR & MAGNETIC EFFECTS */
.cursor-tracking { cursor: none; position: relative; }
.magnetic-button { position: relative; }
.magnetic-button:hover { animation: magneticPull 0.3s ease-out; }
.parallax-element { will-change: transform; }
.parallax-element:hover { animation: parallaxShift 0.5s ease-in-out infinite; }

/* 2. PARTICLE EFFECTS */
.particle-float { animation: floatParticle 3s ease-in forwards; }
.particle-float.delayed-1 { animation-delay: 0.1s; }
.particle-float.delayed-2 { animation-delay: 0.2s; }
.particle-float.delayed-3 { animation-delay: 0.3s; }
.orbiting-element { animation: orb 8s ease-in-out infinite; }
.gradient-shift { 
  background-size: 200% 200%;
  animation: gradientShift 6s ease infinite;
}
.mouse-trail { animation: mouseTrail 0.8s ease-out forwards; }

/* 3. NOTIFICATION EFFECTS */
.toast { animation: toastSlide 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
.toast.stack-nth-1 { animation: toastStack 0.3s ease 0.1s both; }
.toast.stack-nth-2 { animation: toastStack 0.3s ease 0.2s both; }
.toast.stack-nth-3 { animation: toastStack 0.3s ease 0.3s both; }
.toast.dismiss { animation: toastDismiss 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }
.toast-progress { animation: progressSlide 5s linear; }
.toast-badge { animation: badgePopIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1); }
.bubble { animation: bubbleRise 2s ease-out forwards; }
.bubble.bubble-delay-1 { animation-delay: 0.1s; }
.bubble.bubble-delay-2 { animation-delay: 0.2s; }
.bubble.bubble-delay-3 { animation-delay: 0.3s; }

/* 4. FORM INTERACTIONS */
.form-validated { animation: validationCheck 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); }
.form-error-shake { animation: validationError 0.4s ease; }
.strength-indicator { animation: strengthFill var(--strength-duration, 0.6s) ease; }
.char-count-active { animation: charCountPulse 0.5s ease infinite; }
.autocomplete-menu { animation: autocompleteDrop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
.collapsible-section { animation: sectionCollapse 0.3s ease forwards; }
.collapsible-section.open { animation: none; max-height: 500px; opacity: 1; }

/* 5. SCROLLING EFFECTS */
.scroll-progress { animation: scrollProgress linear; animation-timeline: view(); }
.fade-on-scroll { animation: fadeInOnScroll linear; animation-timeline: view(); }
.scroll-trigger-spin { animation: scrollTriggerSpin linear; animation-timeline: view(); }
.crossfade-transition { animation: crossFade 0.6s ease-in-out; }
.parallax-scroll { will-change: transform; }

/* 6. DATA VISUALIZATION */
.count-up-number { animation: countUp var(--count-duration, 2s) ease-out; }
.chart-bar-animate { animation: chartBarDraw 0.8s ease-out forwards; }
.chart-bar-animate.delay-1 { animation-delay: 0.1s; }
.chart-bar-animate.delay-2 { animation-delay: 0.2s; }
.chart-bar-animate.delay-3 { animation-delay: 0.3s; }
.chart-line-animate { animation: chartLineDraw 1.2s ease-out forwards; }
.data-point { animation: dataPointPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1); }
.data-point.delay-1 { animation-delay: 0.1s; }
.data-point.delay-2 { animation-delay: 0.2s; }
.progress-ring { animation: progressRingFill 1s ease-out forwards; }
.gauge-needle { animation: gaugeNeedle 1.5s cubic-bezier(0.34, 1.56, 0.64, 1); }

/* 7. GLASSMORPHISM */
.glass-effect {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
}
.glass-shimmer { animation: glassShimmer 3s ease-in-out infinite; }
.glass-glow { animation: glassGlow 2s ease-in-out infinite; }
.glass-reflection { animation: reflectionShift 2s ease-in-out infinite; }

/* 8. DASHBOARD WIDGETS */
.widget-resizable { position: relative; }
.resize-handle { animation: resizeHandle 1s ease-in-out infinite; }
.widget-dragging { animation: widgetShuffle 0.4s ease; }
.widget-collapsing { animation: widgetCollapse 0.3s ease forwards; }
.widget-expanding { animation: widgetOpen 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }

/* 9. COLOR THEMING */
.theme-transition { animation: themeTransition 0.6s ease; }
.theme-accent-pulse { animation: accentPulseTheme 2s ease-in-out infinite; }
.theme-time-based { animation: timeBasedTheme 12h linear infinite; }

/* 10. TEXT ANIMATIONS */
.char-reveal { animation: characterReveal 0.5s ease-out backwards; }
.char-reveal.char-1 { animation-delay: 0.05s; }
.char-reveal.char-2 { animation-delay: 0.1s; }
.char-reveal.char-3 { animation-delay: 0.15s; }
.word-highlight { animation: wordHighlight 1s ease-in-out infinite; }
.typing-text { animation: typingEffect 1.5s steps(40, end) 1s forwards; overflow: hidden; white-space: nowrap; }
.number-scramble { animation: numberScramble 0.4s ease; }
.letter-expand { animation: letterSpaceExpand 0.5s ease; }

/* 11. CHART INTERACTIONS */
.chart-updating { animation: chartUpdate 0.5s ease; }
.legend-item-hidden { animation: legendToggle 0.3s ease; opacity: 0.3; }
.data-series-highlight { animation: dataSeriesHighlight 0.4s ease; }
.chart-zoom-in { animation: chartZoom 0.5s ease; }
.export-flash { animation: exportFlash 0.6s ease; }

/* 12. LOADING STATES */
.skeleton { 
  background: linear-gradient(90deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05), rgba(255,255,255,0.1));
  background-size: 200% 100%;
  animation: skeletonWave 2s infinite;
}
.skeleton-pulse { animation: skeletonPulse 1.5s ease-in-out infinite; }
.preview-blur { animation: previewBlur 0.8s ease; }
.loading-timer { animation: timeRemaining 1s ease-in-out infinite; }

/* 13. HOVER CASCADE */
.hover-parent:hover .hover-child {
  animation: childHoverStagger 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hover-child-1 { animation-delay: 0s; }
.hover-child-2 { animation-delay: 0.08s; }
.hover-child-3 { animation-delay: 0.16s; }
.hover-child-4 { animation-delay: 0.24s; }
.blur-background { animation: hoverBackgroundBlur 0.3s ease; }
.hover-color-shift { animation: hoverColorShift 0.4s ease; }
.hover-shadow-grow { animation: hoverShadowGrow 0.5s ease; }
.cascade-scale { animation: scaleCascade 0.6s ease; }

/* 14. GESTURE & SWIPE */
.swipe-reveal { animation: swipeReveal 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }
.swipe-return { animation: swipeReturn 0.3s ease forwards; }
.dragging-item { animation: dragGlow 0.5s ease infinite; }
.drop-zone-active { animation: dropZoneHighlight 1s ease infinite; }

/* 15. STATUS INDICATORS */
.status-pulse { animation: statusPulse 2s ease-in-out infinite; }
.status-pulse-fast { animation: statusPulse 1s ease-in-out infinite; }
.status-timeline { animation: statusTimeline 0.5s ease; }
.activity-bar { animation: activityBar 0.6s ease infinite; }
.signal-bar { animation: signalStrength 0.5s ease; }
.status-color-fade { animation: statusColorFade 1.5s ease infinite; }

/* 16. SOUND INDICATORS */
.sound-wave { animation: soundWave 0.4s ease infinite; }
.sound-wave.wave-1 { animation-delay: 0s; }
.sound-wave.wave-2 { animation-delay: 0.1s; }
.sound-wave.wave-3 { animation-delay: 0.2s; }
.vibration-effect { animation: vibrationPulse 0.2s ease infinite; }

/* 17. MENU ANIMATIONS */
.menu-slide-left { animation: menuSlideLeft 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
.menu-slide-right { animation: menuSlideRight 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
.menu-item { animation: menuItemStagger 0.4s ease backwards; }
.menu-item-1 { animation-delay: 0s; }
.menu-item-2 { animation-delay: 0.08s; }
.menu-item-3 { animation-delay: 0.16s; }
.menu-item-4 { animation-delay: 0.24s; }
.nested-menu { animation: nestedMenuSlide 0.3s ease; }
.hamburger-icon { animation: hamburgerX 0.4s ease; }
.menu-hover-bg { animation: menuHoverSlide 0.6s ease; }

/* 18. MODAL ANIMATIONS */
.modal-open { animation: modalScaleIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
.modal-backdrop { animation: backdropBlur 0.3s ease; }
.modal-stacked { animation: modalStackOffset 0.4s ease forwards; }
.modal-close { animation: modalDismiss 0.3s ease forwards; }
.modal-button { animation: buttonSlideIn 0.4s ease 0.1s both; }

/* 19. SHADOW & DEPTH */
.shadow-expand { animation: shadowExpand 0.5s ease; }
.ao-shadow { animation: ambientOcclusion 1.5s ease-in-out infinite; }
.elevated-1 { box-shadow: 0 2px 4px rgba(0,0,0,0.2); }
.elevated-2 { box-shadow: 0 4px 8px rgba(0,0,0,0.25); }
.elevated-3 { box-shadow: 0 8px 16px rgba(0,0,0,0.3); }
.elevated-4 { box-shadow: 0 16px 32px rgba(0,0,0,0.35); }

/* 20. GAMIFICATION */
.confetti { animation: confetti 2s ease-out forwards; }
.confetti-1 { --x: 20px; animation-delay: 0s; }
.confetti-2 { --x: -20px; animation-delay: 0.05s; }
.confetti-3 { --x: 40px; animation-delay: 0.1s; }
.confetti-4 { --x: -40px; animation-delay: 0.15s; }
.achievement { animation: achievementUnlock 0.6s cubic-bezier(0.34, 1.56, 0.64, 1); }
.level-up { animation: levelUpFlash 0.8s ease; }
.star { animation: starFill 0.6s ease forwards; }
.badge-unlock { animation: badgeUnlock 0.8s cubic-bezier(0.34, 1.56, 0.64, 1); }

/* 21. FILTERING & SEARCH */
.results-item { animation: resultsStagger 0.4s ease backwards; }
.results-item-1 { animation-delay: 0s; }
.results-item-2 { animation-delay: 0.08s; }
.results-item-3 { animation-delay: 0.16s; }
.filter-badge { animation: filterBadgeAppear 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
.filter-badge-remove { animation: filterBadgeFly 0.3s ease forwards; }
.search-input-active { animation: searchInputGlow 1.5s ease-in-out infinite; }
.result-count { animation: resultCountPulse 0.4s ease; }

/* 22. TIMELINE */
.timeline-entry { animation: timelineEntrySlide 0.5s ease backwards; }
.timeline-entry-1 { animation-delay: 0s; }
.timeline-entry-2 { animation-delay: 0.1s; }
.timeline-entry-3 { animation-delay: 0.2s; }
.timeline-connector { animation: timelineConnectorDraw 0.8s ease; }
.timeline-date { animation: timelineDatePop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1); }
.milestone { animation: milestonePulse 2s ease-in-out infinite; }
.progress-timeline { animation: timelineProgressFill 1.5s ease; }

/* 23. CARD EXPANSIONS */
.expandable-card { animation: cardExpand 0.4s ease; }
.card-flip { animation: cardFlip 0.6s ease; }
.card-detail { animation: detailOverlaySlide 0.4s ease; }
.card-hover-magnify { animation: cardMagnify 0.3s ease; }

/* 24. ACCESSIBILITY */
.high-contrast { animation: highContrastTransition 0.3s ease; }
.focus-ring { animation: focusRingPulse 0.5s ease infinite; }
.text-scale-large { animation: fontSizeTransition 0.3s ease; font-size: 18px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* 25. ICON ANIMATIONS */
.icon-spin { animation: iconSpin 2s linear infinite; }
.icon-spin-fast { animation: iconSpin 1s linear infinite; }
.icon-draw { animation: iconStrokeDraw 0.8s ease forwards; }
.icon-fill { animation: iconFill 0.6s ease forwards; }
.icon-crossfade { animation: iconCrossFade 0.5s ease; }
.icon-glow { animation: iconGlowPulse 1.5s ease-in-out infinite; }

/* ==================== COMBINATION EFFECTS ==================== */

/* Magnetic + hover */
.magnetic-hover:hover {
  animation: magneticPull 0.3s ease-out;
  box-shadow: 0 0 30px rgba(0,230,255,0.4);
}

/* Particle burst */
.particle-burst { animation: floatParticle 2s ease-out forwards; }
.particle-burst:nth-child(1) { --angle: 0deg; animation-delay: 0s; }
.particle-burst:nth-child(2) { --angle: 72deg; animation-delay: 0.05s; }
.particle-burst:nth-child(3) { --angle: 144deg; animation-delay: 0.1s; }
.particle-burst:nth-child(4) { --angle: 216deg; animation-delay: 0.15s; }
.particle-burst:nth-child(5) { --angle: 288deg; animation-delay: 0.2s; }

/* Stagger container */
.stagger-container > * {
  animation: fadeInScale 0.4s ease backwards;
}
.stagger-container > *:nth-child(1) { animation-delay: 0s; }
.stagger-container > *:nth-child(2) { animation-delay: 0.08s; }
.stagger-container > *:nth-child(3) { animation-delay: 0.16s; }
.stagger-container > *:nth-child(4) { animation-delay: 0.24s; }
.stagger-container > *:nth-child(5) { animation-delay: 0.32s; }

/* Smooth transitions */
.transition-all { transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
.transition-fast { transition: all 0.15s ease; }
.transition-slow { transition: all 0.6s ease; }

/* Performance utilities */
.gpu-accelerate {
  transform: translate3d(0, 0, 0);
  will-change: transform;
}

.gpu-accelerate-all {
  transform: translate3d(0, 0, 0);
  will-change: transform, opacity;
}

/* Reduce motion accessibility */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* High contrast mode support */
@media (prefers-contrast: more) {
  .glass-effect {
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
  }
  
  .statCard {
    border-left: 3px solid rgba(0,230,255,0.8);
  }
}

/* Dark mode enhancements */
@media (prefers-color-scheme: dark) {
  .glass-effect {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  
  .status-pulse {
    box-shadow: 0 0 0 0 rgba(0,230,255,0.7);
  }
}

/* Light mode adjustments */
@media (prefers-color-scheme: light) {
  .particle-float {
    opacity: 0.8;
  }
  
  .glass-effect {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
  }
}

/* Mobile optimizations */
@media (max-width: 768px) {
  .toast { animation: toastSlide 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
  .modal-open { animation: modalScaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); }
  .menu-slide-left, .menu-slide-right { animation-duration: 0.3s; }
  
  /* Reduce particle effects on mobile */
  .particle-float { animation-duration: 2s; }
  .orbiting-element { animation-duration: 6s; }
}

/* Tablet optimizations */
@media (min-width: 769px) and (max-width: 1024px) {
  .widget-resizable {
    min-width: 250px;
    min-height: 200px;
  }
}

/* Desktop enhancements */
@media (min-width: 1025px) {
  .magnetic-button:hover { animation-duration: 0.2s; }
  .parallax-element:hover { animation: parallaxShift 0.4s ease-in-out infinite; }
}

/* Performance mode */
.performance-mode * {
  animation-duration: 0.2s !important;
  transition-duration: 0.1s !important;
}
.logsList .logRow .controls{ margin-left:auto; display:flex; gap:8px; align-items:center; }
.logsList .logRow .controls .btn{ padding:6px 10px; border-radius:8px; background: rgba(255,255,255,0.02); border:1px solid rgba(255,255,255,0.04); color:rgba(200,255,255,0.9); cursor:pointer; }
.logsList .logRow .controls .btn:hover{ background: rgba(0,230,255,0.06); }

/* Backward compatibility: the logs renderer creates .logEntry elements - style them the same */
.logsList .logEntry{ padding:12px; border-radius:10px; background: linear-gradient(180deg, rgba(255,255,255,0.01), rgba(255,255,255,0.006)); border:1px solid rgba(255,255,255,0.03); transition: transform 180ms ease, box-shadow 180ms ease; }
.logsList .logEntry:hover{ transform: translateY(-4px); box-shadow: 0 10px 30px rgba(0,0,0,0.45); }
.logsList .logEntry .logBadge{ display:inline-block; background: linear-gradient(90deg, rgba(0,230,255,0.12), rgba(59,224,201,0.06)); color:#cff2f7; padding:4px 8px; border-radius:8px; font-weight:700; font-size:11px; margin-left:8px; }
.logsList .logEntry .logWithdrawBtn{ padding:8px 12px; border-radius:10px; background: linear-gradient(90deg, rgba(0,0,0,0.04), rgba(255,255,255,0.01)); border:1px solid rgba(255,255,255,0.04); color:rgba(200,255,255,0.95); cursor:pointer; }
.logsList .logEntry .logWithdrawBtn:hover{ background: rgba(0,230,255,0.06); }
.rankComponent .rankMilestones{ display:flex; gap:8px; margin-top:6px; align-items:center; }
.rankComponent .milestone{ font-size:12px; padding:6px 8px; border-radius:8px; background:transparent; color:rgba(230,255,255,0.75); border:1px dashed rgba(255,255,255,0.03); display:inline-flex; align-items:center; gap:8px; }
.rankComponent .milestone .mIcon{ width:14px; height:14px; display:inline-block; }
.rankComponent .milestone.active{ background:rgba(0,230,255,0.06); color:#dffcff; border:1px solid rgba(0,230,255,0.08); transform:translateY(-2px); box-shadow:0 8px 20px rgba(0,230,255,0.06); }
.milestone.pulse{ animation: milestonePulse 900ms ease; }
@keyframes milestonePulse{ 0%{ transform:scale(1); opacity:1 } 40%{ transform:scale(1.12); opacity:1 } 100%{ transform:scale(1); opacity:1 } }

.rankComponent .rankMeta{ display:flex; justify-content:space-between; align-items:center; gap:12px; margin-top:6px; color:rgba(200,230,240,0.85); font-size:13px; }
.rankComponent .nextThreshold{ font-weight:600; color:rgba(180,235,255,0.95); }

/* Modal for detailed rank info */
.rankModalOverlay{ position:fixed; inset:0; background:rgba(0,0,0,0.6); display:flex; align-items:center; justify-content:center; z-index:12000; opacity:0; pointer-events:none; transition:opacity 180ms ease; }
.rankModalOverlay.visible{ opacity:1; pointer-events:auto; }
.rankModal{ width:380px; max-width:92%; background:linear-gradient(180deg, rgba(4,39,53,0.95), rgba(0,18,35,0.98)); border-radius:12px; padding:18px; box-shadow:0 20px 60px rgba(0,0,0,0.6); border:1px solid rgba(255,255,255,0.03); }
.rankModal h4{ margin:0 0 8px 0; font-size:16px; }
.rankModal .rankList{ display:flex; flex-direction:column; gap:8px; margin-top:12px; }
.rankModal .rankRow{ display:flex; justify-content:space-between; align-items:center; padding:10px; border-radius:8px; background:rgba(255,255,255,0.02); }
.rankModal .rankRow.current{ box-shadow:0 8px 24px rgba(0,230,255,0.06) inset; border:1px solid rgba(0,230,255,0.06); }
.rankModal .closeBtn{ margin-top:12px; display:inline-block; padding:8px 12px; border-radius:8px; background:transparent; border:1px solid rgba(255,255,255,0.06); color:var(--text); cursor:pointer; }

/* toast */
.toast {
  position: fixed;
  right: 20px;
  bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.3px;
  z-index: 2000;
  opacity: 0;
  transform: translateY(16px) scale(0.95);
  transition: opacity 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px rgba(0, 230, 255, 0.1);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  max-width: 420px;
  word-wrap: break-word;
}

.toast.show {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.toast-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  width: 20px;
  height: 20px;
  font-size: 16px;
  font-weight: bold;
  flex-shrink: 0;
}

.toast-content {
  line-height: 1.4;
}

.toast.success {
  background: linear-gradient(135deg, rgba(0, 200, 100, 0.15), rgba(0, 255, 150, 0.08));
  color: #00ff99;
  border-color: rgba(0, 255, 150, 0.3);
}

.toast.success .toast-icon {
  color: #00ff99;
}

.toast.error {
  background: linear-gradient(135deg, rgba(255, 50, 100, 0.15), rgba(255, 100, 150, 0.08));
  color: #ff6b9d;
  border-color: rgba(255, 100, 150, 0.3);
}

.toast.error .toast-icon {
  color: #ff6b9d;
}

.toast.info {
  background: linear-gradient(135deg, rgba(0, 150, 255, 0.15), rgba(0, 200, 255, 0.08));
  color: #00d4ff;
  border-color: rgba(0, 200, 255, 0.3);
}

.toast.info .toast-icon {
  color: #00d4ff;
}

.toast.warning {
  background: linear-gradient(135deg, rgba(255, 180, 0, 0.15), rgba(255, 220, 50, 0.08));
  color: #ffd700;
  border-color: rgba(255, 220, 50, 0.3);
}

.toast.warning .toast-icon {
  color: #ffd700;
}

/* compile card background SVG animation */
.compileCard{ position: relative; overflow: visible; }
.compileCard .bgSvg{ position: absolute; right: -30px; top: -18px; width: 220px; height: 120px; opacity:0.12; pointer-events:none; }
.compileCard .bgPath{ stroke: rgba(0,230,255,0.5); stroke-width:2; fill: none; stroke-dasharray: 400; stroke-dashoffset: 400; transition: stroke-dashoffset 900ms cubic-bezier(.2,.9,.2,1), opacity 400ms ease; }
.compileCard.revealed .bgPath{ stroke-dashoffset: 0; opacity: 0.95; }
.compileResult{ 
  min-width:320px; 
  max-width:640px; 
  width:60%; 
  padding:16px; 
  border-radius:14px; 
  background: linear-gradient(180deg, rgba(0,0,0,0.08), rgba(255,255,255,0.02)); 
  border:1px solid rgba(255,255,255,0.04); 
  opacity:0; 
  transform: translateY(6px); 
  transition: opacity .28s ease, transform .28s ease;
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}
.compileResult.visible{ 
  opacity:1; 
  transform: translateY(0); 
}
.snippetArea{ 
  width:100%; 
  height:120px; 
  padding:16px; 
  border-radius:12px; 
  background: rgba(0,0,0,0.08); 
  color:var(--text); 
  border:1px solid rgba(255,255,255,0.06);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, 'Roboto Mono', 'Courier New', monospace; 
  font-size:14px;
  line-height: 1.5;
}
.copyBtn, .copyBtn.copied{ transition: all .18s ease; }
.compileCard::after{ content: ''; position: absolute; pointer-events:none; }
.btnSecondary {
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
  color: rgba(230, 255, 255, 0.7);
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.3px;
}

/* Custom scrollbar for compile/result areas to match UI aesthetic */
.compileResult, .snippetArea {
  scrollbar-width: thin; /* Firefox */
  scrollbar-color: rgba(0,230,255,0.6) rgba(255,255,255,0.04);
}

/* Webkit-based browsers */
.compileResult::-webkit-scrollbar, .snippetArea::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
.compileResult::-webkit-scrollbar-track, .snippetArea::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.03);
  border-radius: 10px;
}
.compileResult::-webkit-scrollbar-thumb, .snippetArea::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(0,230,255,0.28), rgba(59,224,201,0.22));
  border-radius: 10px;
  border: 2px solid rgba(255,255,255,0.03);
}
.compileResult::-webkit-scrollbar-thumb:hover, .snippetArea::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(0,230,255,0.42), rgba(59,224,201,0.36));
}

/* Ensure textarea scrollbars have matching padding and background */
.snippetArea { background: rgba(0,0,0,0.06); }

/* Make copy buttons consistent size */
.copyBtn {
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.06);
  background: linear-gradient(90deg, rgba(0,230,255,0.08), rgba(59,224,201,0.04));
  color: #002;
  font-weight: 700;
  cursor: pointer;
}
.copyBtn.copied{ transform: translateY(-2px); }

/* Dropdown/select scrollbar styling for WebKit (affects expanded dropdown in Chrome/Edge/Safari) */
.compileCard select::-webkit-scrollbar { width: 10px; height: 10px; }
.compileCard select::-webkit-scrollbar-track { background: rgba(255,255,255,0.03); border-radius: 8px; }
.compileCard select::-webkit-scrollbar-thumb { background: linear-gradient(180deg, rgba(0,230,255,0.28), rgba(59,224,201,0.22)); border-radius: 8px; border: 2px solid rgba(255,255,255,0.03); }

/* Option styling fallback */
.compileCard select option { background: rgba(0,0,0,0.06); color: var(--text); }

.btnSecondary:hover {
  background: rgba(0, 230, 255, 0.08);
  border-color: rgba(0, 230, 255, 0.3);
  color: rgba(0, 230, 255, 0.9);
  box-shadow: 0 4px 12px rgba(0, 230, 255, 0.1);
  transform: translateY(-1px);
}

.btnSecondary:active {
  transform: translateY(0);
}
.formActions{ display:flex; gap:10px; align-items:center; margin-top:8px; justify-content:flex-start; }

/* chat */
.chatBox{
  margin-top: 20px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.006));
  border-radius: 16px;
  padding: 16px;
  max-height: 380px;
  overflow: auto;
  border: 1px solid rgba(255,255,255,0.03);
  box-shadow: 
    inset 0 2px 4px rgba(0,0,0,0.1),
    0 4px 16px rgba(0,0,0,0.1);
}
.chatMessage{ 
  margin-bottom: 12px;
  animation: slideIn 0.3s ease-out;
}
.chatInput{ 
  display: flex; 
  gap: 10px; 
  margin-top: 12px;
}
.chatInput input{
  flex: 1;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.06);
  background: rgba(255,255,255,0.02);
  color: var(--text);
  outline: none;
  transition: all 0.2s ease;
  font-size: 15px;
}
.chatInput input:focus {
  border-color: rgba(0,230,255,0.2);
  background: rgba(255,255,255,0.03);
  box-shadow: 0 0 0 4px rgba(0,230,255,0.1);
}
.chatInput button{
  padding: 12px 18px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #012;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 15px;
  box-shadow: 0 4px 12px rgba(0,210,220,0.2);
}
.chatInput button:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0,210,220,0.3);
}

/* Chat bubble styles */
.chatMessage{ 
  display: flex; 
  gap: 12px; 
  margin-bottom: 16px; 
  align-items: flex-start; 
  animation: msgIn .3s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.chatRow{ 
  display: flex; 
  gap: 12px; 
  align-items: flex-start; 
  width: 100%;
}
.chatAvatar{ 
  width: 40px; 
  height: 40px; 
  border-radius: 12px; 
  display: inline-flex; 
  align-items: center; 
  justify-content: center; 
  font-weight: 700; 
  color: #012; 
  background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(245,255,255,0.98)); 
  box-shadow: 
    0 8px 20px rgba(0,0,0,0.2),
    0 0 0 1px rgba(255,255,255,0.1); 
  flex: 0 0 40px;
  transition: transform 0.2s ease;
}
.chatAvatar:hover {
  transform: scale(1.05);
}
.chatBody{ 
  display: flex; 
  flex-direction: column; 
  gap: 8px; 
  max-width: calc(100% - 52px);
}
.chatMeta{ 
  font-size: 13px; 
  color: rgba(200,230,235,0.9); 
  display: flex; 
  justify-content: space-between; 
  align-items: center;
  padding: 0 2px;
}
.chatUser{ 
  font-weight: 700; 
  color: var(--text);
  text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}
.chatTime{ 
  font-weight: 600; 
  color: rgba(200,230,235,0.8); 
  font-size: 12px;
}
.chatBubble{ 
  padding: 12px 16px; 
  border-radius: 14px; 
  background: linear-gradient(135deg, rgba(255,255,255,0.14), rgba(255,255,255,0.08)); 
  color: var(--text);
  box-shadow: 
    0 8px 24px rgba(0,0,0,0.15),
    0 2px 4px rgba(0,0,0,0.1),
    inset 0 0 0 1px rgba(255,255,255,0.05); 
  word-break: break-word;
  line-height: 1.5;
  font-size: 15px;
  transition: transform 0.2s ease;
}
.chatBubble:hover {
  transform: translateY(-1px);
  box-shadow: 
    0 12px 28px rgba(0,0,0,0.18),
    0 2px 4px rgba(0,0,0,0.1),
    inset 0 0 0 1px rgba(255,255,255,0.08);
}
.chatMessage.mine .chatAvatar{ color:#012; }
.chatMessage.mine .chatBubble{ 
  background: linear-gradient(90deg, rgba(0,230,255,0.18), rgba(59,224,201,0.14)); 
  color:var(--text);
  align-self:flex-end; 
}
.chatMessage.mine .chatMeta{ color:rgba(0,230,255,0.95); }
.chatMessage:not(.mine) .chatBubble{ align-self:flex-start; }

/* Mentioned message highlight */
.chatMessage.mentioned .chatBubble{
  box-shadow: 0 6px 18px rgba(0,230,255,0.15);
  border: 1px solid rgba(0,230,255,0.2);
  animation: mentionPulse 2s ease-out;
}
@keyframes mentionPulse{
  0%{ box-shadow: 0 6px 18px rgba(0,230,255,0.15); }
  50%{ box-shadow: 0 6px 28px rgba(0,230,255,0.25); }
  100%{ box-shadow: 0 6px 18px rgba(0,230,255,0.15); }
}

/* Wallet copy buttons */
.copyBtn{
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  padding: 6px 10px;
  margin: -4px 0 -4px 8px;
  cursor: pointer;
  color: rgba(200,230,235,0.8);
  border-radius: 8px;
  transition: all 0.2s ease;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.copyBtn:hover{ 
  color: var(--text); 
  background: rgba(255,255,255,0.08);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,210,220,0.1);
}
.copyBtn.copied{
  color: var(--accent);
  background: rgba(0,230,255,0.1);
  border-color: rgba(0,230,255,0.2);
  animation: copiedPop 0.3s ease-out;
}
@keyframes copiedPop{
  0%, 100%{ transform: scale(1); }
  50%{ transform: scale(1.2); }
}

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

@keyframes spin{ 0%{ transform: rotate(0deg); } 100%{ transform: rotate(360deg); } }

/* Enhanced button disabled state */\nbutton:disabled {\n  opacity: 0.5;\n  cursor: not-allowed;\n}\n\nbutton:disabled:hover {\n  transform: none !important;\n}\n\n/* Mobile improvements */
@media (max-width: 520px) {
  .chatBubble{
    font-size: 15px;
    padding: 12px 14px;
  }
  .compileBtn{ width:100%; height:48px; min-width: auto; }
  .compileResult{ width:100%; min-width:0; }
  .chatAvatar{
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
  }
  .walletValue{
    font-size: 14px;
    line-height: 1.4;
  }
}

/* small text */
.small{ font-size:13px; color:rgba(230,255,255,0.8); }

/* responsive */
@media (max-width:920px){
  .panel{ padding:18px; min-height:560px }
  .layout{ grid-template-columns: 1fr 320px; }
  .logo{ width:48px; height:48px }
  .title{ font-size:16px }
}
@media (max-width:520px){
  .panel{ padding:12px; width:95vw; min-height:640px }
  .logo{ width:40px; height:40px }
  .tabs{ gap:8px; margin-top:8px }
  .tab{ padding:8px 12px; font-size:13px }
@media (max-width: 768px){
  .authCard{ width:95vw; padding:32px 24px; }
  .authBrand{ margin-bottom:24px; }
  .authBrandTitle{ font-size:24px; }
  .authTitleSection{ flex-direction:column; gap:12px; }
  .authToggleBtn{ align-self:flex-start; }
}
  /* collapse chat into bottom on narrow screens */
  .layout{ grid-template-columns: 1fr; }
  .chatColumn{ order: 2; width:100%; max-width:none; }
  .content{ order:1; }
}