/* =============================================
   IRAQ LOVE CHAT - Special Entry Effects CSS
   effects.css - Visual effects for admin/owner/moderator entry
   ============================================= */

/* ══════════════════════════════════════════
   ENTRY ANNOUNCEMENT BOX
══════════════════════════════════════════ */

.entry-announcement {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.7);
  z-index: 9000;
  pointer-events: none;
  opacity: 0;
  transition: none;
}

.entry-announcement.show {
  animation: entryBoxAppear 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.5) forwards;
}

.entry-announcement.hide {
  animation: entryBoxDisappear 0.5s ease forwards;
}

@keyframes entryBoxAppear {
  0%   { opacity: 0; transform: translate(-50%, -50%) scale(0.5); }
  100% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

@keyframes entryBoxDisappear {
  0%   { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(0.8) translateY(-20px); }
}

.entry-box {
  position: relative;
  min-width: 340px;
  max-width: 480px;
  padding: 28px 36px;
  border-radius: 20px;
  text-align: center;
  overflow: hidden;
  backdrop-filter: blur(20px);
  box-shadow:
    0 0 60px rgba(0,0,0,0.8),
    inset 0 0 60px rgba(255,255,255,0.03);
}

.entry-username {
  font-size: 28px;
  font-weight: 900;
  font-family: 'Tajawal', sans-serif;
  letter-spacing: -0.5px;
  position: relative;
  z-index: 2;
  display: block;
}

.entry-subtitle {
  font-size: 14px;
  font-weight: 500;
  font-family: 'Tajawal', sans-serif;
  opacity: 0.75;
  margin-top: 6px;
  position: relative;
  z-index: 2;
  display: block;
  direction: rtl;
}

.entry-role-icon {
  font-size: 42px;
  display: block;
  margin-bottom: 10px;
  position: relative;
  z-index: 2;
}

/* ══════════════════════════════════════════
   1. OWNER ENTRY — 4K WOLF ARCTIC BLIZZARD EFFECT
══════════════════════════════════════════ */

.entry-box.owner-entry,
.entry-box.wolf-entry {
  background: radial-gradient(circle at 50% 20%, rgba(10, 25, 48, 0.95), rgba(4, 8, 20, 0.98));
  border: 2px solid rgba(0, 240, 255, 0.85);
  box-shadow:
    0 0 70px rgba(0, 188, 255, 0.6),
    0 0 140px rgba(0, 119, 255, 0.35),
    inset 0 0 45px rgba(0, 240, 255, 0.2),
    0 0 80px rgba(0,0,0,0.9);
  padding: 24px 32px;
}

.wolf-entry-badge {
  position: relative;
  width: 140px;
  height: 140px;
  margin: 0 auto 14px auto;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, #00f0ff, #0077ff, #3b82f6, #00f0ff);
  background-size: 300% 300%;
  animation: wolfBadgeSpin 4s linear infinite;
  box-shadow: 0 0 35px rgba(0, 240, 255, 0.8), 0 0 60px rgba(0, 119, 255, 0.5);
}

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

.wolf-entry-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
  filter: contrast(1.1) brightness(1.05);
}

.wolf-entry-vid {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
  filter: contrast(1.1) brightness(1.08);
}

/* Owner entry prominent title */
.owner-entry-title {
  font-size: 22px;
  font-weight: 900;
  text-align: center;
  margin: 8px 0 4px;
  letter-spacing: 2px;
  background: linear-gradient(90deg, #f59e0b, #ff6600, #fff, #f59e0b);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: ownerNameShimmer 1.2s linear infinite;
  filter: drop-shadow(0 0 14px rgba(255, 165, 0, 0.9));
  text-shadow: none;
}

.wolf-entry-halo {
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 2px dashed rgba(0, 240, 255, 0.6);
  animation: rotateHalo 12s linear infinite;
  pointer-events: none;
}
@keyframes rotateHalo {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

.entry-box.owner-entry .entry-username,
.entry-box.wolf-entry .entry-username {
  background: linear-gradient(90deg, #00bcff, #00f0ff, #0077ff, #3b82f6, #00bcff);
  background-size: 400% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: ownerNameShimmer 0.8s linear infinite;
  text-shadow: none;
  filter: drop-shadow(0 0 20px rgba(0, 188, 255, 0.9));
}

@keyframes ownerNameShimmer {
  0%   { background-position: 0% center; }
  100% { background-position: 400% center; }
}

.entry-box.owner-entry .entry-subtitle,
.entry-box.wolf-entry .entry-subtitle { color: #00f0ff; }

/* Canvas overlay */
.owner-entry-canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

/* Screen flash effect */
.screen-flash {
  position: fixed;
  inset: 0;
  background: rgba(255, 200, 50, 0.15);
  z-index: 8999;
  pointer-events: none;
  animation: screenFlashAnim 0.15s ease forwards;
}
.screen-flash.wolf-screen-flash {
  background: radial-gradient(circle, rgba(0, 240, 255, 0.35) 0%, rgba(0, 119, 255, 0.15) 60%, transparent 100%);
}
@keyframes screenFlashAnim {
  0%   { opacity: 1; }
  100% { opacity: 0; }
}

/* Screen shake for owner */
.shake-active {
  animation: screenShake 0.4s cubic-bezier(0.36,0.07,0.19,0.97) forwards !important;
}
@keyframes screenShake {
  0%,100% { transform: translateX(0); }
  10%      { transform: translateX(-6px) rotate(-0.5deg); }
  20%      { transform: translateX(6px) rotate(0.5deg); }
  30%      { transform: translateX(-5px); }
  40%      { transform: translateX(5px); }
  50%      { transform: translateX(-3px); }
  60%      { transform: translateX(3px); }
  70%      { transform: translateX(-2px); }
  80%      { transform: translateX(2px); }
}

/* ══════════════════════════════════════════
   2. ADMIN ENTRY — SMOKE EFFECT
══════════════════════════════════════════ */

.entry-box.admin-entry {
  background: rgba(10, 8, 25, 0.90);
  border: 2px solid rgba(245, 158, 11, 0.7);
  box-shadow:
    0 0 60px rgba(245, 158, 11, 0.4),
    0 0 120px rgba(245, 158, 11, 0.15),
    inset 0 0 40px rgba(245, 158, 11, 0.08),
    0 0 60px rgba(0,0,0,0.8);
}

.entry-box.admin-entry .entry-username {
  background: linear-gradient(90deg, #f59e0b, #fbbf24, #f59e0b);
  background-size: 200% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: adminNameShimmer 1.2s ease-in-out infinite;
  filter: drop-shadow(0 0 14px rgba(245,158,11,0.8));
}
@keyframes adminNameShimmer {
  0%,100% { background-position: 0% center; filter: drop-shadow(0 0 14px rgba(245,158,11,0.8)); }
  50%      { background-position: 200% center; filter: drop-shadow(0 0 24px rgba(251,191,36,1)); }
}
.entry-box.admin-entry .entry-subtitle { color: #fcd34d; }

/* Smoke particles */
.smoke-particle {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(180,180,200,0.35) 0%, rgba(100,100,130,0.15) 40%, transparent 70%);
  animation: smokeRise var(--dur, 2.5s) ease-out var(--delay, 0s) infinite;
  pointer-events: none;
  z-index: 1;
  transform-origin: center bottom;
}

@keyframes smokeRise {
  0% {
    opacity: 0;
    transform: translate(var(--tx, 0px), 20px) scale(0.3);
  }
  15% {
    opacity: 0.7;
  }
  100% {
    opacity: 0;
    transform: translate(calc(var(--tx, 0px) * 1.8), -120px) scale(2.5) rotate(var(--rot, 30deg));
  }
}

/* ══════════════════════════════════════════
   3. MODERATOR ENTRY — ELECTRIC SPARKS
══════════════════════════════════════════ */

.entry-box.mod-entry {
  background: rgba(5, 15, 20, 0.90);
  border: 2px solid rgba(16, 185, 129, 0.7);
  box-shadow:
    0 0 60px rgba(16, 185, 129, 0.4),
    0 0 120px rgba(16, 185, 129, 0.15),
    inset 0 0 40px rgba(16, 185, 129, 0.08),
    0 0 60px rgba(0,0,0,0.8);
}

.entry-box.mod-entry .entry-username {
  background: linear-gradient(90deg, #10b981, #34d399, #6ee7b7, #34d399, #10b981);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: modNameShimmer 1.5s linear infinite;
  filter: drop-shadow(0 0 12px rgba(16,185,129,0.9));
}
@keyframes modNameShimmer {
  0%   { background-position: 0% center; }
  100% { background-position: 300% center; }
}
.entry-box.mod-entry .entry-subtitle { color: #6ee7b7; }

/* Spark particles */
.spark-particle {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #7fffd4;
  box-shadow: 0 0 6px #10b981, 0 0 12px #10b981;
  animation: sparkFly var(--dur, 0.8s) ease-out var(--delay, 0s) infinite;
  pointer-events: none;
  z-index: 3;
}
@keyframes sparkFly {
  0% {
    opacity: 1;
    transform: translate(0,0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--dx, 30px), var(--dy, -40px)) scale(0.2);
  }
}

/* Electric arc lines */
.electric-line {
  position: absolute;
  height: 2px;
  background: linear-gradient(90deg, transparent, #10b981, #7fffd4, #10b981, transparent);
  opacity: 0;
  animation: electricFlicker 0.3s ease var(--delay, 0s) infinite;
  pointer-events: none;
  z-index: 2;
  border-radius: 2px;
  box-shadow: 0 0 8px #10b981;
}
@keyframes electricFlicker {
  0%,100% { opacity: 0; }
  50%      { opacity: 0.9; }
}

/* ══════════════════════════════════════════
   MOVING BLUE COLOR (Owner Name in chat)
══════════════════════════════════════════ */

.moving-blue-text {
  background: linear-gradient(90deg,
    #00bcff, #0077ff, #00f0ff, #0077ff, #00bcff, #3b82f6, #00bcff);
  background-size: 400% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: movingBlue 3s linear infinite;
  font-weight: 900 !important;
  filter: drop-shadow(0 0 8px rgba(0, 188, 255, 0.6));
}
@keyframes movingBlue {
  0%   { background-position: 0% center; }
  100% { background-position: 400% center; }
}

/* Owner name glow pulse */
.owner-name-glow {
  animation: ownerGlow 2s ease-in-out infinite;
}
@keyframes ownerGlow {
  0%,100% { filter: drop-shadow(0 0 4px rgba(0, 188, 255, 0.4)); }
  50%      { filter: drop-shadow(0 0 14px rgba(0, 188, 255, 0.9)) drop-shadow(0 0 28px rgba(0, 240, 255, 0.5)); }
}

/* Admin name gold shimmer */
.admin-name-gold {
  color: #f59e0b !important;
  text-shadow: 0 0 10px rgba(245,158,11,0.6), 0 0 20px rgba(245,158,11,0.3);
  animation: adminGold 2.5s ease-in-out infinite;
  font-weight: 800 !important;
}
@keyframes adminGold {
  0%,100% { text-shadow: 0 0 10px rgba(245,158,11,0.6); }
  50%      { text-shadow: 0 0 20px rgba(245,158,11,0.9), 0 0 35px rgba(245,158,11,0.5); }
}

/* Moderator name emerald */
.mod-name-emerald {
  color: #10b981 !important;
  text-shadow: 0 0 8px rgba(16,185,129,0.5);
  animation: modEmerald 2s ease-in-out infinite;
  font-weight: 800 !important;
}
@keyframes modEmerald {
  0%,100% { text-shadow: 0 0 8px rgba(16,185,129,0.5); }
  50%      { text-shadow: 0 0 18px rgba(16,185,129,0.9), 0 0 30px rgba(16,185,129,0.4); }
}

/* ══════════════════════════════════════════
   PARTICLE CANVAS (Full screen background)
══════════════════════════════════════════ */
#effects-canvas {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 8998;
  opacity: 0;
  transition: opacity 0.3s;
}
#effects-canvas.active { opacity: 1; }

/* ── Loading Spinner ── */
.spinner {
  width: 20px; height: 20px;
  border: 2px solid rgba(255,255,255,0.2);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ══════════════════════════════════════════
   3D GIFT THEMES & PARTICLE BURST EFFECTS
══════════════════════════════════════════ */

.gift-particle {
  position: absolute;
  font-size: 18px;
  pointer-events: none;
  z-index: 5;
  animation: floatParticle var(--dur) ease-in-out var(--delay) infinite;
  transform-style: preserve-3d;
  opacity: 0;
  text-shadow: 0 0 10px rgba(255,255,255,0.8);
}

@keyframes floatParticle {
  0% {
    transform: translate3d(0, 0, 0) scale(0.5);
    opacity: 0;
  }
  20% {
    opacity: 1;
  }
  80% {
    opacity: 1;
  }
  100% {
    transform: translate3d(var(--tx), var(--ty), var(--tz)) scale(1.2) rotate(360deg);
    opacity: 0;
  }
}

/* 1. Butterflies Themed 3D Card */
.gift-card-butterflies {
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.25), rgba(16, 185, 129, 0.25)) !important;
  border: 2px solid rgba(244, 114, 182, 0.9) !important;
  box-shadow: 
    0 0 50px rgba(236, 72, 153, 0.6),
    0 0 90px rgba(52, 211, 153, 0.35),
    inset 0 0 25px rgba(255, 255, 255, 0.4) !important;
}

/* 2. Supercar Themed 3D Card */
.gift-card-supercar {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(6, 182, 212, 0.25)) !important;
  border: 2px solid rgba(6, 182, 212, 0.9) !important;
  box-shadow: 
    0 0 55px rgba(6, 182, 212, 0.65),
    0 0 95px rgba(239, 68, 68, 0.45),
    inset 0 0 25px rgba(255, 255, 255, 0.35) !important;
}

/* 3. Princess Themed 3D Card */
.gift-card-princess {
  background: linear-gradient(135deg, rgba(147, 197, 253, 0.25), rgba(240, 248, 255, 0.35)) !important;
  border: 2px solid rgba(186, 230, 253, 0.9) !important;
  box-shadow: 
    0 0 55px rgba(56, 189, 248, 0.65),
    0 0 110px rgba(147, 197, 253, 0.45),
    inset 0 0 30px rgba(255, 255, 255, 0.5) !important;
  backdrop-filter: blur(16px);
}

/* 4. Fire Tiger Themed 3D Card */
.gift-card-tiger {
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.3), rgba(220, 38, 38, 0.35)) !important;
  border: 2px solid rgba(249, 115, 22, 0.9) !important;
  box-shadow: 
    0 0 60px rgba(249, 115, 22, 0.75),
    0 0 120px rgba(220, 38, 38, 0.55),
    inset 0 0 30px rgba(254, 215, 170, 0.4) !important;
}

/* 5. Joker Themed 3D Card */
.gift-card-joker {
  background: linear-gradient(135deg, rgba(147, 51, 234, 0.35), rgba(16, 185, 129, 0.25)) !important;
  border: 2px solid rgba(168, 85, 247, 0.9) !important;
  box-shadow: 
    0 0 60px rgba(147, 51, 234, 0.75),
    0 0 110px rgba(16, 185, 129, 0.45),
    inset 0 0 30px rgba(233, 213, 255, 0.4) !important;
}

/* 6. King Heavenly Themed 3D Card */
.gift-card-king_heavenly {
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.35), rgba(255, 255, 255, 0.3)) !important;
  border: 2.5px solid rgba(250, 204, 21, 0.95) !important;
  box-shadow: 
    0 0 70px rgba(250, 204, 21, 0.85),
    0 0 130px rgba(254, 240, 138, 0.55),
    inset 0 0 35px rgba(255, 255, 255, 0.6) !important;
}

/* 7. King Lion Themed 3D Card */
.gift-card-king_lion {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.35), rgba(180, 83, 9, 0.4)) !important;
  border: 2.5px solid rgba(245, 158, 11, 0.95) !important;
  box-shadow: 
    0 0 75px rgba(245, 158, 11, 0.85),
    0 0 140px rgba(217, 119, 6, 0.55),
    inset 0 0 35px rgba(253, 230, 138, 0.5) !important;
}

/* ══════════════════════════════════════════
   CUSTOM MEMBER ENTRY EFFECT
══════════════════════════════════════════ */

.entry-box.custom-member-entry {
  background: linear-gradient(135deg, rgba(10,6,30,0.92), rgba(5,5,18,0.97));
  border: 2px solid rgba(139,92,246,0.75);
  box-shadow:
    0 0 60px rgba(139,92,246,0.55),
    0 0 120px rgba(236,72,153,0.35),
    inset 0 0 30px rgba(139,92,246,0.1);
  padding: 0;
  overflow: hidden;
  min-width: 320px;
  max-width: 460px;
  border-radius: 22px;
}

.custom-entry-vid-wrap {
  width: 100%;
  height: 240px;
  overflow: hidden;
  position: relative;
  border-radius: 20px 20px 0 0;
}

.custom-entry-vid {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.custom-entry-title {
  font-size: 18px;
  font-weight: 900;
  text-align: center;
  padding: 10px 20px 4px;
  background: linear-gradient(90deg, #8b5cf6, #ec4899, #8b5cf6);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: ownerNameShimmer 1.5s linear infinite;
  filter: drop-shadow(0 0 10px rgba(139,92,246,0.7));
  direction: rtl;
}

.custom-member-entry .entry-username {
  font-size: 20px;
  font-weight: 900;
  display: block;
  text-align: center;
  padding: 4px 20px 14px;
  color: #e0d7ff;
  filter: drop-shadow(0 0 8px rgba(139,92,246,0.8));
}

/* Effects admin toggle switch styles */
.effects-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  gap: 12px;
}
.effects-toggle-row:last-child { border-bottom: none; }

.toggle-switch {
  position: relative;
  display: inline-block;
  width: 52px;
  height: 28px;
  flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: rgba(255,255,255,0.12);
  border-radius: 34px;
  transition: 0.3s;
}
.toggle-slider::before {
  content: '';
  position: absolute;
  height: 20px; width: 20px;
  left: 4px; bottom: 4px;
  background: #fff;
  border-radius: 50%;
  transition: 0.3s;
}
.toggle-switch input:checked + .toggle-slider { background: linear-gradient(135deg,#8b5cf6,#ec4899); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(24px); }
