/* Animations & Custom Styles */

/* Parallax Background */
.parallax-bg {
  transform: translateZ(-1px) scale(1.5);
  will-change: transform;
}

/* Floating Animation */
@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-20px);
  }
}

.animate-float {
  animation: float 3s ease-in-out infinite;
}

/* Particle Animations */
.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: radial-gradient(circle, #06b6d4, transparent);
  border-radius: 50%;
  opacity: 0.6;
  animation: particle-float 15s infinite ease-in-out;
}

.particle-1 {
  top: 20%;
  left: 10%;
  animation-delay: 0s;
  animation-duration: 12s;
}

.particle-2 {
  top: 60%;
  left: 80%;
  animation-delay: 2s;
  animation-duration: 15s;
}

.particle-3 {
  top: 40%;
  left: 30%;
  animation-delay: 4s;
  animation-duration: 18s;
}

.particle-4 {
  top: 80%;
  left: 60%;
  animation-delay: 1s;
  animation-duration: 14s;
}

.particle-5 {
  top: 30%;
  left: 90%;
  animation-delay: 3s;
  animation-duration: 16s;
}

@keyframes particle-float {
  0%,
  100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.6;
  }
  25% {
    transform: translate(50px, -50px) scale(1.2);
    opacity: 0.8;
  }
  50% {
    transform: translate(-30px, -100px) scale(0.8);
    opacity: 0.4;
  }
  75% {
    transform: translate(70px, -70px) scale(1.1);
    opacity: 0.7;
  }
}

/* Marquee Animation */
.marquee-container {
  position: relative;
  width: 100%;
}

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

.marquee-content:hover {
  animation-play-state: paused;
}

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

/* Adding comprehensive prose styling for markdown content with proper contrast and responsive design */

/* Prose Container */
.prose {
  max-width: 100%;
  color: #e5e7eb;
  font-size: 1rem;
  line-height: 1.75;
}

/* Prose Headings */
.prose h2 {
  color: #06b6d4;
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  margin-top: 2.5em;
  margin-bottom: 1em;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.prose h3 {
  color: #8b5cf6;
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  font-weight: 600;
  margin-top: 2em;
  margin-bottom: 0.75em;
  line-height: 1.4;
}

.prose h4 {
  color: #c084fc;
  font-size: clamp(1.125rem, 2.5vw, 1.25rem);
  font-weight: 600;
  margin-top: 1.75em;
  margin-bottom: 0.5em;
  line-height: 1.5;
}

/* Prose Paragraphs */
.prose p {
  margin-top: 0;
  margin-bottom: 1.5em;
  line-height: 1.8;
  color: #d1d5db;
}

.prose p:first-of-type {
  font-size: 1.0625rem;
  line-height: 1.85;
}

/* Prose Links */
.prose a {
  color: #06b6d4;
  text-decoration: underline;
  text-decoration-color: rgba(6, 182, 212, 0.3);
  text-underline-offset: 0.2em;
  font-weight: 500;
  transition: all 0.2s ease;
}

.prose a:hover {
  color: #8b5cf6;
  text-decoration-color: rgba(139, 92, 246, 0.5);
}

/* Prose Lists */
.prose ul,
.prose ol {
  margin-top: 1.25em;
  margin-bottom: 1.25em;
  padding-left: 1.75em;
}

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

.prose ol {
  list-style-type: decimal;
}

.prose li {
  margin-top: 0.5em;
  margin-bottom: 0.5em;
  line-height: 1.75;
  color: #d1d5db;
}

.prose li::marker {
  color: #8b5cf6;
  font-weight: 600;
}

.prose ul ul,
.prose ul ol,
.prose ol ul,
.prose ol ol {
  margin-top: 0.75em;
  margin-bottom: 0.75em;
}

.prose li > p {
  margin-top: 0.75em;
  margin-bottom: 0.75em;
}

/* Prose Strong & Em */
.prose strong {
  color: #f3f4f6;
  font-weight: 600;
}

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

/* Prose Blockquotes */
.prose blockquote {
  font-style: italic;
  color: #c0c0d8;
  border-left: 0.25rem solid #8b5cf6;
  padding-left: 1.5em;
  padding-top: 0.5em;
  padding-bottom: 0.5em;
  margin-top: 2em;
  margin-bottom: 2em;
  background: rgba(139, 92, 246, 0.05);
  border-radius: 0 0.5rem 0.5rem 0;
}

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

/* Prose Tables */
.prose table {
  width: 100%;
  max-width: 100%;
  border-collapse: collapse;
  margin-top: 2em;
  margin-bottom: 2em;
  font-size: 0.9375rem;
  line-height: 1.6;
}

.prose thead {
  background: rgba(139, 92, 246, 0.15);
  border-bottom: 2px solid #8b5cf6;
}

.prose thead th {
  color: #f3f4f6;
  font-weight: 600;
  text-align: left;
  padding: 0.875rem 1rem;
  vertical-align: bottom;
}

.prose tbody tr {
  border-bottom: 1px solid rgba(139, 92, 246, 0.1);
  transition: background-color 0.2s ease;
}

.prose tbody tr:hover {
  background: rgba(6, 182, 212, 0.05);
}

.prose tbody td {
  padding: 0.875rem 1rem;
  color: #d1d5db;
  vertical-align: top;
}

.prose tbody tr:last-child {
  border-bottom: none;
}

/* Table Responsive Wrapper */
.prose .table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 2em 0;
  border-radius: 0.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

.prose .table-responsive table {
  margin: 0;
}

/* Prose Images */
.prose img {
  max-width: 100%;
  height: auto;
  border-radius: 0.75rem;
  margin-top: 2em;
  margin-bottom: 2em;
  box-shadow: 0 10px 30px -10px rgba(139, 92, 246, 0.3);
}

/* Prose Code */
.prose code {
  color: #06b6d4;
  background: rgba(6, 182, 212, 0.1);
  padding: 0.2em 0.4em;
  border-radius: 0.25rem;
  font-size: 0.875em;
  font-family: ui-monospace, monospace;
}

.prose pre {
  background: rgba(10, 14, 39, 0.8);
  border: 1px solid rgba(139, 92, 246, 0.2);
  border-radius: 0.5rem;
  padding: 1.25em;
  overflow-x: auto;
  margin-top: 2em;
  margin-bottom: 2em;
}

.prose pre code {
  background: transparent;
  padding: 0;
  color: #e5e7eb;
  font-size: 0.875rem;
  line-height: 1.7;
}

/* Prose Horizontal Rule */
.prose hr {
  border: none;
  border-top: 1px solid rgba(139, 92, 246, 0.2);
  margin-top: 3em;
  margin-bottom: 3em;
}

/* Responsive Prose Adjustments */
@media (max-width: 768px) {
  .prose {
    font-size: 0.9375rem;
  }

  .prose table {
    font-size: 0.875rem;
  }

  .prose thead th,
  .prose tbody td {
    padding: 0.625rem 0.75rem;
  }

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

  .prose blockquote {
    padding-left: 1em;
    margin-left: 0;
    margin-right: 0;
  }
}

@media (max-width: 640px) {
  .prose {
    font-size: 0.875rem;
  }

  .prose table {
    font-size: 0.8125rem;
  }

  .prose thead th,
  .prose tbody td {
    padding: 0.5rem;
  }
}

/* Print Styles for Prose */
@media print {
  .prose {
    color: #000;
  }

  .prose h2,
  .prose h3,
  .prose h4 {
    color: #000;
    page-break-after: avoid;
  }

  .prose a {
    color: #000;
    text-decoration: underline;
  }

  .prose table {
    page-break-inside: avoid;
  }
}

/* Table Responsive Wrapper */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1.5rem 0;
}

/* Smooth Transitions */
* {
  transition-property: color, background-color, border-color, transform, opacity;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: #8b5cf6;
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: #06b6d4;
}

/* Focus Styles for Accessibility */
a:focus,
button:focus,
details:focus {
  outline: 2px solid #06b6d4;
  outline-offset: 2px;
}

/* Details/Summary Styling */
details summary::-webkit-details-marker {
  display: none;
}

details[open] summary {
  border-bottom: 1px solid rgba(139, 92, 246, 0.2);
  margin-bottom: 1rem;
}

/* Glow Effects */
.hover\:shadow-lunar-violet\/50:hover {
  box-shadow: 0 20px 50px -12px rgba(139, 92, 246, 0.5);
}

.hover\:shadow-lunar-violet\/30:hover {
  box-shadow: 0 10px 30px -10px rgba(139, 92, 246, 0.3);
}

/* Mobile Menu Transitions */
#mobile-menu {
  transition: all 0.3s ease-in-out;
}

/* Responsive Typography */
@media (max-width: 640px) {
  .prose-custom p {
    text-align: left;
  }
}

/* Print Styles */
@media print {
  .parallax-bg,
  .particle,
  header,
  footer,
  .marquee-container {
    display: none;
  }
}
