/* ── Base ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }

/* ── Gradient text ── */
.text-gradient {
  background: linear-gradient(135deg, #34d399 0%, #10b981 50%, #059669 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Glass card ── */
.glass-card {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.glass-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(16, 185, 129, 0.2);
  box-shadow: 0 8px 40px -12px rgba(16, 185, 129, 0.15),
              inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transform: translateY(-4px);
}

/* ── Nav glass ── */
#nav.scrolled {
  background: rgba(10, 10, 10, 0.7);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

/* ── Reveal animation ── */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Tech card ── */
.tech-card {
  opacity: 0;
  transform: translateY(24px) scale(0.95);
  transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.tech-card.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* ── Project card ── */
.project-card {
  opacity: 0;
  transform: translateY(32px);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.project-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Project card glow on hover ── */
.project-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(16, 185, 129, 0.06), transparent 40%);
  opacity: 0;
  transition: opacity 0.4s;
  pointer-events: none;
}
.project-card:hover::before {
  opacity: 1;
}

/* ── Pulsing blobs ── */
@keyframes pulse-slow {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.8; transform: scale(1.1); }
}
@keyframes pulse-slow-delay {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.15); }
}
.animate-pulse-slow { animation: pulse-slow 8s ease-in-out infinite; }
.animate-pulse-slow-delay { animation: pulse-slow-delay 10s ease-in-out infinite 2s; }

/* ── Scroll indicator bounce ── */
@keyframes bounce-slow {
  0%, 100% { transform: translateY(0); opacity: 1; }
  50% { transform: translateY(6px); opacity: 0.4; }
}
.animate-bounce-slow { animation: bounce-slow 2s ease-in-out infinite; }

/* ── Language dot ── */
.lang-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ── Smooth link underline ── */
.nav-link { position: relative; }
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: #34d399;
  transition: width 0.3s;
}
.nav-link:hover::after { width: 100%; }

/* ── Selection ── */
::selection {
  background: rgba(16, 185, 129, 0.3);
  color: white;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(16, 185, 129, 0.2); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(16, 185, 129, 0.4); }

/* ── Tilt effect ── */
.tilt-card {
  transform-style: preserve-3d;
  perspective: 1000px;
}
