@import url("https://fonts.googleapis.com/css2?family=Figtree:wght@300;400;500;600;700;800;900&display=swap");

:root {
  --background: #0a0a0a;
  --foreground: #fafafa;
  --muted: #a1a1aa;
  --surface: #111111;
  --surface-elevated: #1a1a1a;
  --border: rgba(255, 255, 255, 0.08);
  --accent: #c8a2ff;
  --accent-dim: rgba(200, 162, 255, 0.15);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--background);
  color: var(--foreground);
  font-family: "Figtree", system-ui, sans-serif;
  overflow-x: hidden;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

::selection {
  background: var(--accent-dim);
  color: var(--foreground);
}

.gradient-text {
  background: linear-gradient(135deg, #ffffff 0%, #c8a2ff 50%, #ffffff 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@keyframes gradient-shift {
  0% {
    background-position: 0% center;
  }
  100% {
    background-position: 200% center;
  }
}

.gradient-text-animate {
  animation: gradient-shift 4s linear infinite;
}

.gradient-border {
  position: relative;
  background: var(--surface);
  border-radius: 1rem;
}

.gradient-border::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    135deg,
    rgba(200, 162, 255, 0.4),
    rgba(255, 255, 255, 0.05),
    rgba(200, 162, 255, 0.2)
  );
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.hero-glow {
  background: radial-gradient(
    ellipse 80% 50% at 50% -20%,
    rgba(200, 162, 255, 0.15),
    transparent
  );
}

.grid-bg {
  background-image: linear-gradient(
      rgba(255, 255, 255, 0.03) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
}

@keyframes pulse-glow {
  0%,
  100% {
    opacity: 0.4;
  }
  50% {
    opacity: 0.8;
  }
}

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

@keyframes terminal-blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}

.terminal-cursor {
  animation: terminal-blink 1s step-end infinite;
}

.code-terminal {
  border-radius: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 9999px;
  font-weight: 500;
  transition: all 0.3s;
}

.btn-primary {
  background: var(--accent);
  color: var(--background);
  box-shadow: 0 0 30px rgba(200, 162, 255, 0.3);
}

.btn-primary:hover {
  background: rgba(200, 162, 255, 0.9);
}

.btn-secondary {
  background: var(--surface-elevated);
  color: var(--foreground);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: rgba(200, 162, 255, 0.3);
  background: rgba(255, 255, 255, 0.04);
}

.btn-ghost {
  color: var(--muted);
}

.btn-ghost:hover {
  color: var(--foreground);
  background: rgba(255, 255, 255, 0.04);
}

.btn-sm {
  height: 2.25rem;
  padding: 0 1rem;
  font-size: 0.875rem;
}

.btn-md {
  height: 2.5rem;
  padding: 0 1.5rem;
  font-size: 0.875rem;
}

.btn-lg {
  height: 2.75rem;
  padding: 0 1.5rem;
  font-size: 0.875rem;
}

@media (min-width: 640px) {
  .btn-lg {
    padding: 0 1.75rem;
    font-size: 1rem;
  }
}

.btn-youtube {
  background: #ef4444 !important;
  color: #fff !important;
  box-shadow: 0 0 30px rgba(239, 68, 68, 0.3) !important;
}

.btn-youtube:hover {
  background: #dc2626 !important;
}

.filter-btn.active {
  background: var(--accent);
  color: var(--background);
  border-color: transparent;
}

.filter-btn-red.active {
  background: #ef4444;
  color: #fff;
  border-color: transparent;
}

.tab-btn.active {
  background: var(--accent);
  color: var(--background);
  box-shadow: 0 0 20px rgba(200, 162, 255, 0.3);
}

.fade-in {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.course-panel[hidden],
.project-card[hidden],
.blog-card[hidden],
.video-card[hidden] {
  display: none !important;
}
