/* Base styles */
html {
  font-size: 14px;
  scroll-behavior: smooth;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

/* Glassmorphism utilities */
.glass {
  background: rgba(15, 23, 42, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-light {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.glass-card {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Gradient text */
.gradient-text {
  background: linear-gradient(135deg, #a855f7 0%, #ec4899 50%, #06b6d4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.gradient-text-subtle {
  background: linear-gradient(135deg, #c084fc 0%, #f472b6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Gradient backgrounds */
.gradient-bg {
  background: linear-gradient(135deg, #7c3aed 0%, #db2777 50%, #0891b2 100%);
}

.gradient-bg-subtle {
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(236, 72, 153, 0.1) 100%);
}

/* Gradient borders */
.gradient-border {
  position: relative;
}

.gradient-border::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, #a855f7, #ec4899, #06b6d4);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

/* Video background */
.video-hero {
  position: relative;
  overflow: hidden;
}

.video-hero video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%);
  object-fit: cover;
}

.video-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(2, 6, 23, 0.4) 0%,
    rgba(2, 6, 23, 0.6) 50%,
    rgba(2, 6, 23, 0.95) 100%
  );
}

/* Animated gradient background */
.animated-gradient {
  background: linear-gradient(-45deg, #7c3aed, #db2777, #0891b2, #7c3aed);
  background-size: 400% 400%;
  animation: gradientShift 15s ease infinite;
}

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

/* Button styles */
.btn-primary {
  background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #c084fc 0%, #f472b6 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn-primary:hover::before {
  opacity: 1;
}

.btn-primary span {
  position: relative;
  z-index: 1;
}

.btn-outline {
  position: relative;
  background: transparent;
  border: 1px solid rgba(168, 85, 247, 0.5);
  transition: all 0.3s ease;
}

.btn-outline:hover {
  border-color: #a855f7;
  background: rgba(168, 85, 247, 0.1);
}

/* Card hover effects */
.card-hover {
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover:hover {
  transform: translateY(-8px);
  box-shadow: 0 25px 50px -12px rgba(168, 85, 247, 0.25);
}

/* Link hover effect */
.link-hover {
  position: relative;
}

.link-hover::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #a855f7, #ec4899);
  transition: width 0.3s ease;
}

.link-hover:hover::after {
  width: 100%;
}

/* Glow effects */
.glow {
  box-shadow: 0 0 30px rgba(168, 85, 247, 0.3);
}

.glow-text {
  text-shadow: 0 0 40px rgba(168, 85, 247, 0.5);
}

/* Logo glow effect */
.logo-glow {
  filter:
    drop-shadow(0 0 10px rgba(255, 255, 255, 0.95))
    drop-shadow(0 0 22px rgba(168, 85, 247, 0.6))
    drop-shadow(0 0 38px rgba(236, 72, 153, 0.5));
  transition: filter 0.3s ease;
}

.logo-glow:hover {
  filter:
    drop-shadow(0 0 14px rgba(255, 255, 255, 1))
    drop-shadow(0 0 28px rgba(168, 85, 247, 0.75))
    drop-shadow(0 0 48px rgba(236, 72, 153, 0.65));
}

/* Section divider */
.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(168, 85, 247, 0.3), transparent);
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
}

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

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #a855f7, #ec4899);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #c084fc, #f472b6);
}

/* Form focus states */
.form-input {
  transition: all 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(15, 23, 42, 0.6);
}

.form-input:focus {
  outline: none;
  border-color: #a855f7;
  box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.2);
}

/* Badge styles */
.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 9999px;
}

.badge-primary {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(236, 72, 153, 0.2));
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

/* Timeline styles for projects page */
.timeline-item {
  position: relative;
  padding-left: 2rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.5rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: linear-gradient(135deg, #a855f7, #ec4899);
  box-shadow: 0 0 20px rgba(168, 85, 247, 0.5);
}

.timeline-item::after {
  content: '';
  position: absolute;
  left: 5px;
  top: 1.5rem;
  width: 2px;
  height: calc(100% - 0.5rem);
  background: linear-gradient(180deg, rgba(168, 85, 247, 0.5), transparent);
}

.timeline-item:last-child::after {
  display: none;
}

/* Opacity animation helper */
.opacity-0-init {
  opacity: 0;
}

/* Selection styling */
::selection {
  background: rgba(168, 85, 247, 0.4);
  color: white;
}
