/* ========== BASE STYLES ========== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  color: #111827;
  background-color: #f3f4f6;
}

/* ========== HEADER + NAV + HERO (same as main site) ========== */

header {
  background: linear-gradient(135deg, #020617, #111827, #0f766e);
  color: #f9fafb;
  padding-top: 0.5rem;
  padding-bottom: 3rem;
}

/* nav bar */
nav ul {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0.75rem 2rem;
}

nav a {
  color: #e5e7eb;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s;
}

nav a:hover {
  color: #38bdf8;
}

/* hero at top (ABSTRACT FOR ALL) */
.hero {
  text-align: center;
  max-width: 900px;
  margin: 2.5rem auto 0;
  padding: 0 1rem 2.5rem;
}

.hero-title {
  font-size: clamp(2.4rem, 4vw, 3.4rem);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 1rem;

  background: linear-gradient(120deg, #38bdf8, #a855f7, #22c55e);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

.hero-subtitle,
.hero-tagline {
  margin: 0.2rem 0;
  font-size: 1rem;
  color: #e5e7eb;
}

/* ========== PAGE TITLE: PROJECTS (fancy + animated) ========== */

.page-header {
  text-align: center;
  padding: 2.5rem 1rem 1.5rem;
}

.page-header h2 {
  display: inline-block;
  margin: 0;
  font-size: 2.4rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;

  /* gradient text */
  background: linear-gradient(120deg, #38bdf8, #a855f7, #22c55e);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;

  /* layered animations ONLY for this title */
  opacity: 0;
  transform: translateY(10px);
  animation:
    pageTitleIn 0.7s ease-out forwards,
    glowPulse 3s ease-in-out 1.2s infinite,
    shimmer 4s ease-in-out 1.5s infinite;

  position: relative;
}

/* underline under PROJECTS */
.page-header h2::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -0.5rem;
  transform: translateX(-50%) scaleX(0);
  width: 80%;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, #38bdf8, #a855f7, #22c55e);
  animation: underlineReveal 0.8s ease-out 0.6s forwards;
}

/* animations for PROJECTS title */
@keyframes pageTitleIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes glowPulse {
  0% {
    filter: drop-shadow(0 0 0 rgba(168, 85, 247, 0));
  }
  50% {
    filter: drop-shadow(0 0 10px rgba(168, 85, 247, 0.25));
  }
  100% {
    filter: drop-shadow(0 0 0 rgba(168, 85, 247, 0));
  }
}

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

@keyframes underlineReveal {
  from {
    transform: translateX(-50%) scaleX(0);
  }
  to {
    transform: translateX(-50%) scaleX(1);
  }
}

/* ========== PROJECT CARDS ========== */

main {
  max-width: 1200px;
  margin: 0 auto 3rem;
  padding: 0 1rem 3rem;
}

/* card with text left, image right */
.project {
  display: flex;
  flex-direction: row-reverse; /* image right */
  background-color: #ffffff;
  padding: 30px;
  margin: 30px auto;
  border-radius: 14px;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.08);
  max-width: 1100px;
  gap: 30px;
}

/* image box (all equal) */
.project img {
  width: 380px;
  height: 260px;
  object-fit: cover;
  border-radius: 12px;
}

/* text column */
.project-content {
  flex: 1;
}

.project h3 {
  font-size: 1.5rem;
  margin-bottom: 12px;
  color: #0f172a;
}

.project p {
  font-size: 1rem;
  color: #475569;
  line-height: 1.65;
  margin-bottom: 10px;
}

/* mobile layout */
@media (max-width: 900px) {
  .project {
    flex-direction: column;
  }

  .project img {
    width: 100%;
    height: auto;
  }
}

/* ========== FOOTER ========== */

footer {
  font-size: 0.8rem;
  color: #9ca3af;
  text-align: center;
  padding: 20px 0;
  background: #020617;
}
