/* ============================================
   VOLTAGE SPIN THEME - CUSTOM ANIMATIONS & OVERRIDES
   ============================================ */

/* === KEYFRAME ANIMATIONS === */

@keyframes electric-pulse {
  0%, 100% {
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.6),
                0 0 40px rgba(0, 255, 255, 0.4),
                inset 0 0 20px rgba(0, 255, 255, 0.2);
  }
  50% {
    box-shadow: 0 0 30px rgba(0, 255, 255, 0.8),
                0 0 60px rgba(0, 255, 255, 0.6),
                inset 0 0 30px rgba(0, 255, 255, 0.3);
  }
}

@keyframes spark-burst {
  0% {
    transform: scale(0.8) rotate(0deg);
    opacity: 1;
  }
  50% {
    transform: scale(1.2) rotate(180deg);
    opacity: 0.6;
  }
  100% {
    transform: scale(0.8) rotate(360deg);
    opacity: 1;
  }
}

@keyframes neon-flicker {
  0%, 100% { opacity: 1; }
  2%, 8% { opacity: 0.8; }
  4% { opacity: 0.9; }
  6% { opacity: 1; }
}

@keyframes voltage-slide {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

@keyframes marquee-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes parallax-float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-20px); }
}

@keyframes glow-expand {
  0%, 100% {
    text-shadow: 0 0 10px rgba(0, 255, 255, 0.8),
                 0 0 20px rgba(0, 255, 255, 0.6);
  }
  50% {
    text-shadow: 0 0 20px rgba(0, 255, 255, 1),
                 0 0 40px rgba(0, 255, 255, 0.8),
                 0 0 60px rgba(255, 255, 0, 0.4);
  }
}

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

.electric-pulse {
  animation: electric-pulse 2s ease-in-out infinite;
}

.spark-burst {
  animation: spark-burst 3s ease-in-out infinite;
}

.neon-flicker {
  animation: neon-flicker 4s linear infinite;
}

.glow-text {
  animation: glow-expand 3s ease-in-out infinite;
}

.parallax-float {
  animation: parallax-float 6s ease-in-out infinite;
}

.marquee-container {
  overflow: hidden;
  position: relative;
}

.marquee-content {
  display: flex;
  animation: marquee-scroll 30s linear infinite;
}

.marquee-content:hover {
  animation_play_state: paused;
}

/* === NEON BORDERS === */

.neon-border-teal {
  border: 2px solid #00ffff;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.5),
              inset 0 0 10px rgba(0, 255, 255, 0.2);
}

.neon-border-yellow {
  border: 2px solid #ffd700;
  box-shadow: 0 0 10px rgba(255, 215, 0, 0.5),
              inset 0 0 10px rgba(255, 215, 0, 0.2);
}

/* === GLOSSY BLACK SURFACES === */

.glossy-surface {
  background: linear-gradient(145deg, #1a1a1a 0%, #0a0a0a 100%);
  position: relative;
}

.glossy-surface::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1) 0%, transparent 100%);
  pointer-events: none;
}

/* === ELECTRIC GRADIENT OVERLAYS === */

.voltage-gradient {
  background: linear-gradient(135deg, 
    rgba(0, 255, 255, 0.2) 0%,
    rgba(255, 215, 0, 0.2) 100%);
}

.voltage-gradient-reverse {
  background: linear-gradient(135deg, 
    rgba(255, 215, 0, 0.2) 0%,
    rgba(0, 255, 255, 0.2) 100%);
}

/* === SPARK DECORATIONS === */

.spark-decoration {
  position: relative;
}

.spark-decoration::after {
  content: '⚡';
  position: absolute;
  top: -10px;
  right: -10px;
  font-size: 1.5rem;
  color: #ffd700;
  animation: spark-burst 2s ease-in-out infinite;
}

/* === VOLTAGE SLIDER EFFECT === */

.voltage-slider {
  position: relative;
  overflow: hidden;
}

.voltage-slider::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg,
    transparent,
    rgba(0, 255, 255, 0.4),
    transparent);
  animation: voltage-slide 3s ease-in-out infinite;
}

/* === PROSE STYLING FOR READABILITY === */

.prose {
  color: #e0e0e0;
  line-height: 1.75;
  max-width: 100%;
}

.prose h2 {
  color: #00ffff;
  font-weight: 700;
  font-size: clamp(1.5rem, 4vw, 1.875rem);
  margin-top: 2.5em;
  margin-bottom: 1em;
  text-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
  line-height: 1.3;
}

.prose h2:first-child {
  margin-top: 0;
}

.prose h3 {
  color: #ffd700;
  font-weight: 600;
  font-size: clamp(1.25rem, 3.5vw, 1.5rem);
  margin-top: 2em;
  margin-bottom: 0.75em;
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.4);
  line-height: 1.4;
}

.prose p {
  margin-bottom: 1.5em;
  color: #d0d0d0;
  font-size: clamp(1rem, 2vw, 1.125rem);
  line-height: 1.8;
}

.prose p:first-of-type {
  font-size: clamp(1.0625rem, 2.2vw, 1.1875rem);
  line-height: 1.75;
}

.prose strong {
  color: #ffffff;
  font-weight: 600;
}

.prose em {
  color: #ffd700;
  font-style: italic;
}

.prose ul, .prose ol {
  margin-left: 1.5em;
  margin-bottom: 1.5em;
  padding-left: 0;
}

.prose ul {
  list-style-type: none;
}

.prose ul > li {
  position: relative;
  padding-left: 1.75em;
  margin-bottom: 0.75em;
  color: #d0d0d0;
  line-height: 1.7;
}

.prose ul > li::before {
  content: '⚡';
  position: absolute;
  left: 0;
  color: #ffd700;
  font-size: 1em;
}

.prose ol {
  list-style-type: none;
  counter-reset: list-counter;
}

.prose ol > li {
  position: relative;
  padding-left: 2em;
  margin-bottom: 0.75em;
  color: #d0d0d0;
  counter-increment: list-counter;
  line-height: 1.7;
}

.prose ol > li::before {
  content: counter(list-counter) ".";
  position: absolute;
  left: 0;
  color: #00ffff;
  font-weight: 700;
  text-shadow: 0 0 5px rgba(0, 255, 255, 0.4);
}

.prose a {
  color: #00ffff;
  text-decoration: underline;
  text-decoration-color: rgba(0, 255, 255, 0.4);
  text-decoration-thickness: 0.0625em;
  text-underline-offset: 0.125em;
  transition: all 0.3s ease;
}

.prose a:hover {
  color: #ffd700;
  text-decoration-color: rgba(255, 215, 0, 0.6);
  text-shadow: 0 0 8px rgba(255, 215, 0, 0.5);
}

.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 0.5rem;
  border: 2px solid rgba(0, 255, 255, 0.3);
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.3);
  margin: 2em auto;
  display: block;
}

.prose blockquote {
  border-left: 0.25em solid #00ffff;
  padding-left: 1.5em;
  margin: 2em 0;
  font-style: italic;
  color: #b0b0b0;
  background: rgba(0, 255, 255, 0.05);
  padding: 1.5em;
  border-radius: 0.5rem;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.1);
}

.prose blockquote p {
  margin-bottom: 0.5em;
}

.prose table {
  width: 100%;
  max-width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 2em 0;
  font-size: clamp(0.875rem, 1.8vw, 1rem);
}

.prose thead {
  background: linear-gradient(145deg, #1a1a1a 0%, #0a0a0a 100%);
}

.prose th {
  background: linear-gradient(145deg, #1a1a1a 0%, #0a0a0a 100%);
  color: #00ffff;
  padding: 1em;
  text-align: left;
  font-weight: 600;
  border: 1px solid rgba(0, 255, 255, 0.3);
  text-shadow: 0 0 5px rgba(0, 255, 255, 0.3);
}

.prose td {
  background: rgba(26, 26, 26, 0.5);
  color: #d0d0d0;
  padding: 1em;
  border: 1px solid rgba(0, 255, 255, 0.2);
}

.prose tbody tr:hover td {
  background: rgba(0, 255, 255, 0.1);
  transition: background 0.3s ease;
}

.prose hr {
  border: none;
  height: 2px;
  background: linear-gradient(90deg, transparent, #00ffff, transparent);
  margin: 3em 0;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

.prose code {
  background: rgba(0, 255, 255, 0.1);
  color: #ffd700;
  padding: 0.2em 0.4em;
  border-radius: 0.25rem;
  font-size: 0.9em;
  border: 1px solid rgba(0, 255, 255, 0.2);
}

.prose pre {
  background: #0a0a0a;
  border: 2px solid rgba(0, 255, 255, 0.3);
  border-radius: 0.5rem;
  padding: 1.5em;
  overflow-x: auto;
  margin: 2em 0;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.2);
}

.prose pre code {
  background: none;
  border: none;
  padding: 0;
  color: #00ffff;
  font-size: 0.875rem;
}

/* === TABLE RESPONSIVE WRAPPER === */

.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 2em 0;
  border-radius: 0.5rem;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.2);
}

/* === SMOOTH SCROLL === */

html {
  scroll-behavior: smooth;
}

/* === CUSTOM SCROLLBAR === */

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: #0a0a0a;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #00ffff 0%, #ffd700 100%);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #ffd700 0%, #00ffff 100%);
}

/* === BUTTON ENHANCEMENTS === */

.btn-primary-enhanced {
  position: relative;
  overflow: hidden;
}

.btn-primary-enhanced::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-primary-enhanced:hover::before {
  width: 300px;
  height: 300px;
}

/* === MOBILE OPTIMIZATIONS === */

@media (max-width: 768px) {
  .prose h2 {
    margin-top: 2em;
    font-size: 1.5rem;
  }
  
  .prose h3 {
    margin-top: 1.5em;
    font-size: 1.25rem;
  }
  
  .prose ul > li,
  .prose ol > li {
    padding-left: 1.5em;
  }
  
  .prose table {
    font-size: 0.875rem;
  }
  
  .prose th,
  .prose td {
    padding: 0.75em 0.5em;
  }
  
  .spark-decoration::after {
    font-size: 1rem;
    top: -5px;
    right: -5px;
  }
}

/* === PREVENT HORIZONTAL OVERFLOW === */

* {
  box-sizing: border-box;
}

img {
  max-width: 100%;
  height: auto;
}
