@import "tailwindcss";

:root {
  --primary: #5e7ff6;
  --primary-dark: #1d4ed8;
  --secondary: #ca51f5;
  --background: #111827;
  --text: #f9fafb;
}

* {
  box-sizing: border-box;
}

body {
  font-family:
    Verdana, Geneva, Tahoma, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans",
    "Helvetica Neue", sans-serif;
  background-color: var(--background);
  color: var(--text);
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* Плавная прокрутка */
html {
  scroll-behavior: smooth;
}

/* Кастомные анимации */
@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-20px);
  }
}

@keyframes glow {
  0%,
  100% {
    opacity: 0.5;
  }

  50% {
    opacity: 1;
  }
}

@keyframes gradient-shift {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

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

.animate-glow {
  animation: glow 2s ease-in-out infinite;
}

.gradient-shift {
  background-size: 200% 200%;
  animation: gradient-shift 3s ease infinite;
}

/* Кастомные градиенты */
.hero-gradient {
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 50%, #020617 100%);
}

.text-gradient {
  background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #6366f1 100%);
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Эффекты для кнопок */
.btn-glow {
  box-shadow: 0 0 20px rgb(59 130 246 / 30%);
  transition: all 0.3s ease;
}

.btn-glow:hover {
  box-shadow: 0 0 30px rgb(59 130 246 / 50%);
  transform: translateY(-2px);
}

/* Glassmorphism эффекты */
.glass {
  background: rgb(255 255 255 / 5%);
  backdrop-filter: blur(10px);
  border: 1px solid rgb(255 255 255 / 10%);
  box-shadow: 0 8px 32px 0 rgb(31 38 135 / 20%);
}

.glass-dark {
  background: rgb(0 0 0 / 30%);
  backdrop-filter: blur(20px);
  border: 1px solid rgb(255 255 255 / 5%);
  box-shadow: 0 8px 32px 0 rgb(0 0 0 / 40%);
}

/* Специальный glass для навигации - более прозрачный */
.nav-glass {
  background: rgb(17 24 39 / 30%);
  backdrop-filter: blur(20px);
  border: 1px solid rgb(255 255 255 / 4%);
  box-shadow: 0 1px 3px 0 rgb(0 0 0 / 5%);
}

.nav-glass-scrolled {
  background: rgb(17 24 39 / 20%);
  backdrop-filter: blur(20px);
  border: 1px solid rgb(255 255 255 / 8%);
  box-shadow:
    0 4px 16px 0 rgb(0 0 0 / 15%),
    0 8px 32px 0 rgb(17 24 39 / 25%);
  will-change: transform;
}

.glass-card {
  background: linear-gradient(135deg, rgb(255 255 255 / 10%), rgb(255 255 255 / 5%));
  backdrop-filter: blur(15px);
  border: 1px solid rgb(255 255 255 / 8%);
  box-shadow: 0 20px 50px 0 rgb(0 0 0 / 30%);
}

/* Эффекты свечения для glass */
.glass-glow {
  position: relative;
  overflow: hidden;
}

.glass-glow::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: linear-gradient(45deg, #3b82f6, #8b5cf6, #3b82f6);
  background-size: 400% 400%;
  opacity: 0;
  z-index: -1;
  animation: gradient-rotate 3s ease infinite;
  transition: opacity 0.3s ease;
  border-radius: inherit;
}

.glass-glow:hover::before {
  opacity: 0.3;
}

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

/* Noise texture для дополнительного эффекта */
.noise-texture {
  position: relative;
}

.noise-texture::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.02;
  background-image: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 2px,
    rgb(255 255 255 / 10%) 2px,
    rgb(255 255 255 / 10%) 4px
  );
  pointer-events: none;
}

/* 3D Text Effects */
.text-3d {
  transform-style: preserve-3d;
  transform: perspective(1000px);
}

.text-3d-shadow {
  text-shadow:
    0 1px 0 #ccc,
    0 2px 0 #c9c9c9,
    0 3px 0 #bbb,
    0 4px 0 #b9b9b9,
    0 5px 0 #aaa,
    0 6px 1px rgba(0, 0, 0, 0.1),
    0 0 5px rgba(0, 0, 0, 0.1),
    0 1px 3px rgba(0, 0, 0, 0.3),
    0 3px 5px rgba(0, 0, 0, 0.2),
    0 5px 10px rgba(0, 0, 0, 0.25),
    0 10px 10px rgba(0, 0, 0, 0.2),
    0 20px 20px rgba(0, 0, 0, 0.15);
}

/* Animated gradient shift for 3D background */
@keyframes gradient-3d-shift {
  0%,
  100% {
    background-position: 0% 50%;
    filter: hue-rotate(0deg);
  }
  33% {
    background-position: 100% 50%;
    filter: hue-rotate(120deg);
  }
  66% {
    background-position: 50% 100%;
    filter: hue-rotate(240deg);
  }
}

.animate-gradient-3d {
  background-size: 400% 400%;
  animation: gradient-3d-shift 15s ease infinite;
}

/* Cloud animations */
@keyframes cloud-float {
  0% {
    transform: translateX(0) translateY(0);
    opacity: 0.3;
  }
  25% {
    transform: translateX(50px) translateY(-10px);
    opacity: 0.6;
  }
  50% {
    transform: translateX(100px) translateY(0);
    opacity: 0.4;
  }
  75% {
    transform: translateX(50px) translateY(10px);
    opacity: 0.7;
  }
  100% {
    transform: translateX(0) translateY(0);
    opacity: 0.3;
  }
}

.cloud-float {
  animation: cloud-float 20s ease-in-out infinite;
}

/* 3D hover effects */
.hover-3d {
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  transform-style: preserve-3d;
}

.hover-3d:hover {
  transform: perspective(1000px) rotateX(10deg) rotateY(-10deg) translateZ(50px);
  box-shadow:
    0 50px 100px -20px rgba(0, 0, 0, 0.5),
    0 30px 60px -30px rgba(0, 0, 0, 0.7);
}

/* Mountain depth effect */
.mountain-depth {
  position: relative;
  overflow: hidden;
}

.mountain-depth::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(0, 0, 0, 0.1) 30%,
    rgba(0, 0, 0, 0.4) 70%,
    rgba(0, 0, 0, 0.8) 100%
  );
  pointer-events: none;
}

/* Glow effects */
.glow-effect {
  filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.5));
}

.glow-effect-gold {
  filter: drop-shadow(0 0 30px rgba(251, 191, 36, 0.6));
}

/* Cloud floating animations */
@keyframes floatCloud1 {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(100vw + 320px));
  }
}

@keyframes floatCloud2 {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-100vw - 384px));
  }
}

@keyframes floatCloud3 {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(100vw + 288px));
  }
}

/* Shimmer effect for clouds */
@keyframes cloudShimmer {
  0%,
  100% {
    opacity: 0.3;
    filter: blur(20px);
  }
  50% {
    opacity: 0.6;
    filter: blur(30px);
  }
}

.cloud-shimmer {
  animation: cloudShimmer 8s ease-in-out infinite;
}

/* Кастомный скроллбар */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(94, 127, 246, 0.2), rgba(202, 81, 245, 0.2));
  border-radius: 3px;
  transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(94, 127, 246, 0.3), rgba(202, 81, 245, 0.3));
}

/* Firefox scrollbar */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(139, 92, 246, 0.2) transparent;
}

/* Auto-hide scrollbar when not scrolling */
body {
  overflow-y: scroll;
  overflow-x: hidden;
}

/* Prose styles for markdown content */
.prose {
  color: #e5e7eb;
  max-width: 65ch;
}

.prose-invert {
  color: #e5e7eb;
}

.prose-lg {
  font-size: 1.125rem;
  line-height: 1.75;
}

.prose h1 {
  color: #f3f4f6;
  font-size: 2.25rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.prose h2 {
  color: #f3f4f6;
  font-size: 1.5rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.prose h3 {
  color: #f3f4f6;
  font-size: 1.25rem;
  font-weight: 600;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

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

.prose ul {
  list-style-type: disc;
  padding-left: 1.5rem;
  margin-bottom: 1rem;
}

.prose ul li {
  margin-bottom: 0.5rem;
}

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

.prose code {
  background-color: rgb(55 65 81 / 50%);
  padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
  font-size: 0.875em;
}

.prose pre {
  background-color: rgb(31 41 55 / 80%);
  padding: 1rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  margin-bottom: 1rem;
}

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

.prose a:hover {
  color: #93bbfc;
}

/* Common heading styles */
.page-title {
  @apply text-5xl md:text-7xl font-light mb-6 tracking-tight;
}

.section-title {
  @apply text-4xl md:text-5xl mb-12 text-center;
}

.card-title {
  @apply text-2xl font-medium text-white mb-2;
}

.card-description {
  @apply text-gray-400 text-sm;
}

/* Glass card styles */
.glass-card {
  @apply relative overflow-hidden rounded-2xl;
}

.glass-card-bg {
  @apply absolute inset-0 bg-gradient-to-br from-purple-500/10 via-blue-500/10 to-pink-500/10 backdrop-blur-xl;
}

.glass-card-bg-yellow {
  @apply absolute inset-0 bg-gradient-to-br from-yellow-500/10 via-orange-500/10 to-red-500/10 backdrop-blur-xl;
}

.glass-card-bg-green {
  @apply absolute inset-0 bg-gradient-to-br from-green-500/10 via-teal-500/10 to-blue-500/10 backdrop-blur-xl;
}

.glass-card-overlay {
  @apply absolute inset-0 bg-white/[0.02];
}

.glass-card-border {
  @apply absolute inset-0 rounded-2xl bg-gradient-to-br from-purple-500/20 via-transparent to-blue-500/20 p-[1px];
}

.glass-card-border-yellow {
  @apply absolute inset-0 rounded-2xl bg-gradient-to-br from-yellow-500/20 via-transparent to-orange-500/20 p-[1px];
}

.glass-card-border-green {
  @apply absolute inset-0 rounded-2xl bg-gradient-to-br from-green-500/20 via-transparent to-teal-500/20 p-[1px];
}

.glass-card-inner {
  @apply h-full w-full rounded-2xl bg-[#12192C]/90 backdrop-blur-xl;
}

.glass-card-content {
  @apply relative p-6;
}

.primary-0 {
  color: #8b5cf6;
} /* Основной Цвет */
.primary-1 {
  color: #7c62b9;
}
.primary-2 {
  color: #451ea0;
} /* Вторичный Цвет С */
.primary-3 {
  color: #a885fb;
}
.primary-4 {
  color: #bea4fb;
}

.secondary-a-0 {
  color: #ca51f5;
} /* Вторичный Цвет A */
.secondary-a-1 {
  color: #a05bb8;
}
.secondary-a-2 {
  color: #7c1a9f;
}
.secondary-a-3 {
  color: #d97cfa;
}
.secondary-a-4 {
  color: #e29efa;
}

.secondary-b-0 {
  color: #5e7ff6;
} /* Вторичный Цвет B */
.secondary-b-1 {
  color: #6375b8;
}
.secondary-b-2 {
  color: #1f3aa0;
}
.secondary-b-3 {
  color: #879ffa;
}
.secondary-b-4 {
  color: #a5b8fa;
}
