/* ═══════════════════════════════════════════════════════════════════════════
   iBlocker — CSS PERFORMANCE PATCHES
   
   Apply these changes to your styles.css file.
   Each section shows BEFORE → AFTER
   ═══════════════════════════════════════════════════════════════════════════ */


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 1: Glowing Orbs — The #2 performance killer
   
   PROBLEM: filter: blur(80px) on 500px elements + constant animation = 
   GPU renders blur every single frame. This alone can cause lag on 
   older Macs and most Windows laptops.
   
   FIX: Use will-change to promote to GPU layer, reduce blur,
   and pause animation when not needed.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── REPLACE this block: ─── */
/*
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.5;
  animation: orbFloat 8s ease-in-out infinite;
}
*/

/* ─── WITH this: ─── */
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);           /* Reduced from 80px */
  opacity: 0.35;                /* Reduced from 0.5 — less compositing work */
  animation: orbFloat 12s ease-in-out infinite;  /* Slower = less GPU repaints */
  will-change: transform;       /* GPU layer promotion */
  contain: strict;              /* Isolate layout/paint calculations */
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 2: Reduce orb sizes — less pixels to blur
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── REPLACE: ─── */
/*
.hero-orb--cyan {
  width: 500px;
  height: 500px;
  ...
}
.hero-orb--purple {
  width: 400px;
  height: 400px;
  ...
}
.hero-orb--blue {
  width: 300px;
  height: 300px;
  ...
}
*/

/* ─── WITH: ─── */
.hero-orb--cyan {
  width: 350px;                /* Was 500px */
  height: 350px;
  background: var(--accent-cyan);
  top: -150px;
  right: -80px;
  animation-delay: 0s;
}

.hero-orb--purple {
  width: 300px;                /* Was 400px */
  height: 300px;
  background: var(--accent-purple);
  bottom: -120px;
  left: -80px;
  animation-delay: -4s;
}

.hero-orb--blue {
  width: 200px;                /* Was 300px */
  height: 200px;
  background: var(--accent-blue);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: -2s;
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 3: Grid animation — use GPU-friendly transform
   
   PROBLEM: The perspective transform recalculates layout each frame
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── REPLACE: ─── */
/*
.hero-grid {
  ...
  animation: gridMove 20s linear infinite;
  ...
}
*/

/* ─── WITH: ─── */
.hero-grid {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: gridMove 30s linear infinite;  /* Slower — was 20s */
  mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
  will-change: transform;
  contain: strict;
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 4: Feature card hover — avoid layout thrash with translateY
   
   The cards already use translateY which is fine, but adding 
   will-change on hover prevents repaints on the entire section.
   ═══════════════════════════════════════════════════════════════════════════ */

.feature-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 24px;
  padding: 40px;
  position: relative;
  overflow: hidden;
  transition: var(--transition-medium);
  will-change: transform;       /* ADD THIS */
  contain: layout style;        /* ADD THIS */
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 5: Backdrop-filter on navbar — expensive on scroll
   
   The blur recalculates every pixel behind the navbar on every scroll.
   Reduce the blur amount.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── REPLACE: ─── */
/*
.navbar.scrolled {
  background: rgba(10, 14, 26, 0.95);
  backdrop-filter: blur(20px);
  ...
}
*/

/* ─── WITH: ─── */
.navbar.scrolled {
  background: rgba(10, 14, 26, 0.97);    /* More opaque = less blur needed */
  backdrop-filter: blur(10px);             /* Was 20px */
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--glass-border);
  padding: 12px 0;
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 6: Hero image glow — constant blur filter on large element
   ═══════════════════════════════════════════════════════════════════════════ */

/* ─── REPLACE: ─── */
/*
.hero-image::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: var(--gradient-accent);
  border-radius: 26px;
  z-index: -1;
  opacity: 0.5;
  filter: blur(20px);
}
*/

/* ─── WITH: ─── */
.hero-image::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: var(--gradient-accent);
  border-radius: 26px;
  z-index: -1;
  opacity: 0.35;              /* Reduced */
  filter: blur(15px);          /* Reduced from 20px */
  will-change: opacity;        /* Only animates on hover if needed */
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 7: Shimmer animation on notice-bar & buttons
   
   The shimmer pseudo-element animates left continuously.
   Add contain to isolate repaints.
   ═══════════════════════════════════════════════════════════════════════════ */

.notice-bar {
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-blue), var(--accent-purple));
  padding: 10px 20px;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary-900);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  position: relative;
  overflow: hidden;
  contain: layout style;       /* ADD THIS */
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: 12px;
  font-family: 'Orbitron', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: var(--transition-fast);
  border: none;
  position: relative;
  overflow: hidden;
  contain: layout style;       /* ADD THIS */
}


/* ═══════════════════════════════════════════════════════════════════════════
   PATCH 8 (OPTIONAL): Disable heavy effects on low-power devices
   ═══════════════════════════════════════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
  .hero-orb,
  .hero-grid,
  .hero-particles {
    display: none !important;
  }
  
  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* Also disable orbs on mobile — phones struggle with these */
@media (max-width: 768px) {
  .hero-orb {
    display: none;
  }
  
  .hero-grid {
    animation: none;
  }
}


/* ─────────────────────────────────────────────────────────────────────────────
   Hero Quick Access Buttons (FIXED)
   ───────────────────────────────────────────────────────────────────────────── */
.hero-quick-actions {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-bottom: 32px;
  animation: fadeInUp 0.8s ease-out 0.25s both;
}

.quick-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 22px 12px 16px;
  border-radius: 14px;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  max-width: 280px;
}

.quick-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.3s;
}

.quick-btn:hover::before {
  opacity: 1;
}

/* ── Force ALL svgs inside quick-btn to be small ── */
.quick-btn svg {
  width: 20px !important;
  height: 20px !important;
  min-width: 20px;
  min-height: 20px;
  max-width: 20px;
  max-height: 20px;
  flex-shrink: 0;
}

/* ── Panel Login Button ── */
.quick-btn--panel {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.12) 0%, rgba(0, 102, 255, 0.08) 100%);
  border: 1px solid rgba(0, 240, 255, 0.35);
  color: var(--text-primary);
}

.quick-btn--panel::before {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.2) 0%, rgba(0, 102, 255, 0.15) 100%);
}

.quick-btn--panel:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0, 240, 255, 0.25), 0 0 0 1px rgba(0, 240, 255, 0.3);
  color: var(--text-primary);
}

/* ── Community Button ── */
.quick-btn--community {
  background: linear-gradient(135deg, rgba(0, 136, 255, 0.12) 0%, rgba(123, 45, 255, 0.08) 100%);
  border: 1px solid rgba(0, 136, 255, 0.35);
  color: var(--text-primary);
}

.quick-btn--community::before {
  background: linear-gradient(135deg, rgba(0, 136, 255, 0.2) 0%, rgba(123, 45, 255, 0.15) 100%);
}

.quick-btn--community:hover {
  border-color: #0088ff;
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0, 136, 255, 0.25), 0 0 0 1px rgba(0, 136, 255, 0.3);
  color: var(--text-primary);
}

/* ── Icon Container ── */
.quick-btn__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  min-width: 38px;
  border-radius: 10px;
  flex-shrink: 0;
  transition: transform 0.3s, box-shadow 0.3s;
}

.quick-btn--panel .quick-btn__icon {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.2), rgba(0, 102, 255, 0.15));
  border: 1px solid rgba(0, 240, 255, 0.3);
}

.quick-btn--community .quick-btn__icon {
  background: linear-gradient(135deg, rgba(0, 136, 255, 0.2), rgba(123, 45, 255, 0.15));
  border: 1px solid rgba(0, 136, 255, 0.3);
}

.quick-btn:hover .quick-btn__icon {
  transform: scale(1.08);
}

.quick-btn--panel:hover .quick-btn__icon {
  box-shadow: 0 0 14px rgba(0, 240, 255, 0.4);
}

.quick-btn--community:hover .quick-btn__icon {
  box-shadow: 0 0 14px rgba(0, 136, 255, 0.4);
}

.quick-btn--panel .quick-btn__icon svg {
  color: var(--accent-cyan);
}

.quick-btn--community .quick-btn__icon svg {
  color: #0088ff;
}

/* ── Text ── */
.quick-btn__text {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.2;
  font-size: 0.95rem;
}

.quick-btn__text small {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  font-weight: 500;
}

/* ── Arrow ── */
.quick-btn__arrow {
  font-size: 1.1rem;
  color: var(--accent-cyan);
  transition: transform 0.3s;
  margin-left: 2px;
}

.quick-btn--panel:hover .quick-btn__arrow {
  transform: translateX(4px);
}

/* ── Live Pulse Dot ── */
.quick-btn__pulse {
  width: 8px;
  height: 8px;
  background: #00cc66;
  border-radius: 50%;
  margin-left: 2px;
  flex-shrink: 0;
  position: relative;
  animation: livePulse 2s ease-in-out infinite;
}

.quick-btn__pulse::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid rgba(0, 204, 102, 0.4);
  animation: livePulseRing 2s ease-in-out infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(0.85); }
}

@keyframes livePulseRing {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.8); opacity: 0; }
}

/* ── Responsive ── */
@media (max-width: 640px) {
  .hero-quick-actions {
    flex-direction: column;
    align-items: center;
    gap: 10px;
  }

  .quick-btn {
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }
}