/* Arctic Quartz Theme Custom Animations */

/* Parallax Effect */
.parallax-element {
  transform: translateZ(0);
  transition: transform 0.3s ease-out;
}

/* Snowflake Animation */
.snowflake {
  animation: snowfall 8s linear infinite;
}

@keyframes snowfall {
  0% {
    transform: translateY(-100vh) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 1;
  }
  90% {
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(360deg);
    opacity: 0;
  }
}

/* Glowing Arrow Animation */
.glowing-arrow {
  animation: glow-pulse 2s ease-in-out infinite alternate;
  box-shadow: 0 0 20px rgba(64, 224, 208, 0.6);
}

@keyframes glow-pulse {
  0% {
    box-shadow: 0 0 20px rgba(64, 224, 208, 0.6);
    transform: scale(1);
  }
  100% {
    box-shadow: 0 0 30px rgba(64, 224, 208, 0.9);
    transform: scale(1.05);
  }
}

/* Particle Effect Background */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 20% 80%, rgba(64, 224, 208, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(70, 130, 180, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(192, 192, 192, 0.05) 0%, transparent 50%);
  pointer-events: none;
  z-index: -1;
  animation: particle-float 20s ease-in-out infinite;
}

@keyframes particle-float {
  0%,
  100% {
    transform: translateY(0px) rotate(0deg);
  }
  33% {
    transform: translateY(-20px) rotate(120deg);
  }
  66% {
    transform: translateY(10px) rotate(240deg);
  }
}

/* Hover Effects */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

/* Crystalline Border Effect */
.crystal-border {
  position: relative;
  overflow: hidden;
}

.crystal-border::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(64, 224, 208, 0.4), transparent);
  animation: crystal-shine 3s infinite;
}

@keyframes crystal-shine {
  0% {
    left: -100%;
  }
  100% {
    left: 100%;
  }
}

/* Ice Crystal Loading Animation */
.ice-crystal {
  animation: crystal-rotate 4s linear infinite;
}

@keyframes crystal-rotate {
  0% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(180deg) scale(1.1);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

/* Frost Glass Effect */
.frost-glass {
  backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Arctic Gradient Text */
.arctic-gradient-text {
  background: linear-gradient(135deg, #40e0d0, #4682b4, #c0c0c0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Responsive Parallax */
@media (max-width: 768px) {
  .parallax-element {
    transform: none;
  }

  .snowflake {
    animation-duration: 6s;
  }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  .snowflake,
  .glowing-arrow,
  body::before,
  .ice-crystal {
    animation: none;
  }

  .parallax-element {
    transform: none;
  }
}

/* Print Styles */
@media print {
  .snowflake,
  .glowing-arrow,
  body::before {
    display: none;
  }
}

/* Prose Styling for Content Pages */
.prose {
  color: #374151;
  max-width: none;
}

.prose h1 {
  color: #1f2937;
  font-weight: 800;
  font-size: 2.25rem;
  line-height: 2.5rem;
  margin-top: 0;
  margin-bottom: 2rem;
}

.prose h2 {
  color: #1f2937;
  font-weight: 700;
  font-size: 1.875rem;
  line-height: 2.25rem;
  margin-top: 3rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #40e0d0;
}

.prose h3 {
  color: #374151;
  font-weight: 600;
  font-size: 1.5rem;
  line-height: 2rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.prose h4 {
  color: #374151;
  font-weight: 600;
  font-size: 1.25rem;
  line-height: 1.75rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.prose p {
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  line-height: 1.75;
}

.prose a {
  color: #4682b4;
  text-decoration: underline;
  font-weight: 500;
  transition: color 0.2s ease;
}

.prose a:hover {
  color: #40e0d0;
}

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

.prose ul {
  list-style-type: disc;
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  padding-left: 1.625rem;
}

.prose ol {
  list-style-type: decimal;
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  padding-left: 1.625rem;
}

.prose li {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  line-height: 1.75;
}

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

.prose blockquote {
  font-weight: 500;
  font-style: italic;
  color: #1f2937;
  border-left: 0.25rem solid #40e0d0;
  quotes: "\201C" "\201D" "\2018" "\2019";
  margin-top: 1.6rem;
  margin-bottom: 1.6rem;
  padding-left: 1rem;
  background: rgba(64, 224, 208, 0.05);
  padding: 1rem;
  border-radius: 0.5rem;
}

.prose table {
  width: 100%;
  table-layout: auto;
  text-align: left;
  margin-top: 2rem;
  margin-bottom: 2rem;
  font-size: 0.875rem;
  line-height: 1.7142857;
  border-collapse: collapse;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.prose thead {
  background: linear-gradient(135deg, #40e0d0, #4682b4);
  color: white;
}

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

.prose tbody tr {
  border-bottom: 1px solid #e5e7eb;
  background: white;
}

.prose tbody tr:nth-child(even) {
  background: rgba(64, 224, 208, 0.05);
}

.prose tbody tr:hover {
  background: rgba(64, 224, 208, 0.1);
  transition: background-color 0.2s ease;
}

.prose tbody td {
  vertical-align: baseline;
  padding: 1rem 1.5rem;
}

.prose code {
  color: #1f2937;
  font-weight: 600;
  font-size: 0.875rem;
  background: rgba(64, 224, 208, 0.1);
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Consolas, "Liberation Mono", Menlo, monospace;
}

.prose pre {
  color: #e5e7eb;
  background-color: #1f2937;
  overflow-x: auto;
  font-weight: 400;
  font-size: 0.875rem;
  line-height: 1.7142857;
  margin-top: 1.7142857em;
  margin-bottom: 1.7142857em;
  border-radius: 0.375rem;
  padding: 1rem 1.5rem;
}

.prose pre code {
  background-color: transparent;
  border-width: 0;
  border-radius: 0;
  padding: 0;
  font-weight: inherit;
  color: inherit;
  font-size: inherit;
  font-family: inherit;
  line-height: inherit;
}

.prose hr {
  border-color: #d1d5db;
  border-top-width: 1px;
  margin-top: 3rem;
  margin-bottom: 3rem;
}

/* Arctic-themed prose enhancements */
.prose h2::after {
  content: "";
  display: block;
  width: 50px;
  height: 3px;
  background: linear-gradient(90deg, #40e0d0, #4682b4);
  margin-top: 0.5rem;
  border-radius: 2px;
}

.prose blockquote::before {
  content: "\201C";
  font-size: 4rem;
  color: #40e0d0;
  line-height: 0.1em;
  margin-right: 0.25rem;
  vertical-align: -0.4em;
  opacity: 0.5;
}

/* Responsive prose adjustments */
@media (max-width: 768px) {
  .prose h1 {
    font-size: 1.875rem;
    line-height: 2.25rem;
  }

  .prose h2 {
    font-size: 1.5rem;
    line-height: 2rem;
  }

  .prose h3 {
    font-size: 1.25rem;
    line-height: 1.75rem;
  }

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

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

/* Print-friendly prose styles */
@media print {
  .prose {
    color: #000;
  }

  .prose h1,
  .prose h2,
  .prose h3,
  .prose h4 {
    color: #000;
  }

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

  .prose blockquote {
    border-left-color: #000;
    background: none;
  }
}
