/* =============================================
   RESET & BASE
   ============================================= */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: #0d0d1a;
  color: #ffffff;
  font-family: 'Space Grotesk', sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
}

/* =============================================
   BACKGROUND BLOBS
   ============================================= */
.bg-blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.18;
  z-index: -1;
  animation: drift 20s ease-in-out infinite alternate;
  pointer-events: none;
}

.blob-1 {
  width: 600px;
  height: 600px;
  background: #ff6b6b;
  top: -200px;
  left: -200px;
}

.blob-2 {
  width: 500px;
  height: 500px;
  background: #48dbfb;
  bottom: 10%;
  right: -150px;
  animation-delay: -7s;
}

.blob-3 {
  width: 400px;
  height: 400px;
  background: #a29bfe;
  top: 40%;
  left: 40%;
  animation-delay: -14s;
}

@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(40px, 30px) scale(1.08); }
}

/* =============================================
   HERO
   ============================================= */
.hero {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 4rem 2rem;
}

.hero-inner {
  display: flex;
  align-items: center;
  gap: 4rem;
  max-width: 900px;
  width: 100%;
}

/* Avatar ring wrapper — holds the spinning ring pseudo-element */
.hero-avatar-wrap {
  flex-shrink: 0;
  position: relative;
  width: 220px;
  height: 220px;
}

/* Spinning rainbow ring */
.hero-avatar-wrap::before {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff6b6b, #feca57, #48dbfb, #ff9ff3, #a29bfe, #ff6b6b);
  z-index: 0;
  animation: spin-ring 6s linear infinite;
}

/* Dark gap between ring and avatar */
.hero-avatar-wrap::after {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  background: #0d0d1a;
  z-index: 1;
}

@keyframes spin-ring {
  to { transform: rotate(360deg); }
}

.hero-avatar {
  position: relative;
  z-index: 2;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ff6b6b, #feca57);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 4rem;
  font-weight: 800;
  color: #0d0d1a;
  letter-spacing: -2px;
  user-select: none;
}

.hero-text {
  flex: 1;
}

.hero-name {
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 800;
  line-height: 1.1;
  background: linear-gradient(135deg, #ff6b6b, #feca57);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-headline {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  color: rgba(255, 255, 255, 0.55);
  margin-top: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
}

/* =============================================
   PROJECTS SECTION
   ============================================= */
.projects-section {
  padding: 0 2rem 6rem;
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 3rem;
  display: inline-block;
  position: relative;
  left: 50%;
  transform: translateX(-50%);
}

.section-title::after {
  content: '';
  display: block;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(90deg, #48dbfb, #ff9ff3);
  margin-top: 0.5rem;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
}

/* =============================================
   PROJECT CARDS
   ============================================= */
.card {
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
  border-color: rgba(255, 107, 107, 0.5);
}

.card-screenshot {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.card-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #1a1a2e, #16213e);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
}

.card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.5rem;
}

.card-desc {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.65;
  flex: 1;
}

.card-link {
  display: inline-block;
  margin-top: 1.25rem;
  padding: 0.55rem 1.4rem;
  border-radius: 50px;
  background: linear-gradient(135deg, #ff6b6b, #feca57);
  color: #0d0d1a;
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none;
  align-self: flex-start;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.card-link:hover {
  opacity: 0.85;
  transform: scale(1.04);
}

/* Empty state */
.projects-empty {
  color: rgba(255, 255, 255, 0.35);
  text-align: center;
  grid-column: 1 / -1;
  padding: 4rem 0;
  font-size: 1rem;
}

/* =============================================
   FOOTER
   ============================================= */
.site-footer {
  text-align: center;
  padding: 2rem;
  color: rgba(255, 255, 255, 0.25);
  font-size: 0.85rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 640px) {
  .hero-inner {
    flex-direction: column;
    gap: 2rem;
    text-align: center;
  }

  .hero-avatar-wrap,
  .hero-avatar {
    width: 160px;
    height: 160px;
  }

  .hero-avatar {
    font-size: 3rem;
  }

  .card-link {
    align-self: center;
  }
}
