/* ============================================================
   BASE & VARIABLES
   ============================================================ */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --clr-bg: #fafafa;
  --clr-bg-alt: #f0f0f3;
  --clr-surface: #ffffff;
  --clr-text: #1a1a2e;
  --clr-text-muted: #6b7280;
  --clr-primary: #4f46e5;
  --clr-primary-light: #818cf8;
  --clr-primary-bg: #eef2ff;
  --clr-accent: #f59e0b;
  --clr-border: #e5e7eb;
  --font-body: "Inter", sans-serif;
  --font-display: "Playfair Display", serif;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.1);
  --radius: 12px;
  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: var(--font-body);
  color: var(--clr-text);
  background: var(--clr-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 40px;
  background: rgba(250, 250, 250, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.navbar.scrolled {
  border-bottom-color: var(--clr-border);
  box-shadow: var(--shadow-sm);
}

.nav-logo {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--clr-primary);
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 32px;
}

.nav-links a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--clr-text-muted);
  transition: color var(--transition);
  position: relative;
}

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--clr-primary);
  transition: width var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--clr-primary);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--clr-text);
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 120px 40px 80px;
  max-width: 1200px;
  margin: 0 auto;
  gap: 60px;
}

.hero-content {
  flex: 1;
  max-width: 600px;
}

.hero-greeting {
  font-size: 1.1rem;
  color: var(--clr-primary);
  font-weight: 500;
  margin-bottom: 8px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards;
}

.hero-name {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 12px;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.15s forwards;
}

.hero-tagline {
  font-size: 1.15rem;
  color: var(--clr-text-muted);
  margin-bottom: 20px;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.3s forwards;
}

.hero-description {
  font-size: 1.05rem;
  color: var(--clr-text-muted);
  max-width: 480px;
  margin-bottom: 32px;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.45s forwards;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.6s forwards;
}

.hero-visual {
  flex-shrink: 0;
  opacity: 0;
  animation: fadeUp 0.8s ease 0.4s forwards;
}

.hero-photo {
  width: 280px;
  height: 280px;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: var(--shadow-lg);
  border: 4px solid var(--clr-surface);
}

.hero-shape {
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--clr-primary-light), var(--clr-primary));
  opacity: 0.15;
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--clr-primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
}

.btn-primary:hover {
  box-shadow: 0 6px 20px rgba(79, 70, 229, 0.45);
}

.btn-outline {
  border: 2px solid var(--clr-border);
  color: var(--clr-text);
  background: transparent;
}

.btn-outline:hover {
  border-color: var(--clr-primary);
  color: var(--clr-primary);
}

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
  padding: 100px 0;
}

.section-alt {
  background: var(--clr-bg-alt);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  text-align: center;
  margin-bottom: 12px;
}

.section-subtitle {
  text-align: center;
  color: var(--clr-text-muted);
  max-width: 520px;
  margin: 0 auto 56px;
  font-size: 1.05rem;
}

/* ============================================================
   TIMELINE (JOURNEY)
   ============================================================ */
.timeline {
  position: relative;
  max-width: 700px;
  margin: 0 auto;
  padding-left: 40px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--clr-border);
}

.timeline-item {
  position: relative;
  margin-bottom: 48px;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -40px;
  top: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--clr-primary);
  border: 3px solid var(--clr-bg);
  box-shadow: 0 0 0 2px var(--clr-primary);
}

.section-alt .timeline-dot {
  border-color: var(--clr-bg-alt);
}

.timeline-year {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--clr-primary);
  background: var(--clr-primary-bg);
  padding: 2px 10px;
  border-radius: 20px;
  margin-bottom: 8px;
}

.timeline-content h3 {
  font-size: 1.15rem;
  margin-bottom: 6px;
}

.timeline-content p {
  color: var(--clr-text-muted);
  font-size: 0.95rem;
}

.timeline-content a {
  color: var(--clr-primary);
  font-weight: 500;
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition);
}

.timeline-content a:hover {
  border-bottom-color: var(--clr-primary);
}

.timeline-rebrand {
  font-weight: 400;
  color: var(--clr-text-muted);
  font-size: 0.95em;
}

.timeline-expandable {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--clr-border);
}

.timeline-expandable[hidden] {
  display: none;
}

.timeline-expand-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--clr-text);
  margin-bottom: 8px;
}

.timeline-expand-list {
  margin: 0;
  padding-left: 20px;
  color: var(--clr-text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.timeline-view-more {
  margin-top: 10px;
  padding: 0;
  background: none;
  border: none;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--clr-primary);
  cursor: pointer;
  transition: color var(--transition);
}

.timeline-view-more:hover {
  color: var(--clr-primary-light);
}

/* ============================================================
   PROJECTS
   ============================================================ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
}

.project-card {
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: transform var(--transition), box-shadow var(--transition);
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.project-icon {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.project-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}

.project-card p {
  color: var(--clr-text-muted);
  font-size: 0.93rem;
  margin-bottom: 16px;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.project-tags span {
  font-size: 0.78rem;
  font-weight: 500;
  padding: 4px 12px;
  background: var(--clr-primary-bg);
  color: var(--clr-primary);
  border-radius: 20px;
}

.project-link {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--clr-primary);
  transition: gap var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.project-link:hover {
  gap: 8px;
}

/* ============================================================
   INTERESTS
   ============================================================ */
.interests-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.interest-card {
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition);
}

.interest-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.interest-icon {
  font-size: 2.5rem;
  margin-bottom: 14px;
}

.interest-card h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.interest-card p {
  color: var(--clr-text-muted);
  font-size: 0.9rem;
}

.interest-link {
  display: inline-block;
  margin-top: 14px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--clr-primary);
  transition: color var(--transition), transform var(--transition);
}

.interest-link:hover {
  color: var(--clr-primary-light);
}

/* ============================================================
   CONTACT
   ============================================================ */
.contact-container {
  text-align: center;
}

.contact-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 8px;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  background: var(--clr-surface);
  border: 1px solid var(--clr-border);
  border-radius: var(--radius);
  font-size: 0.95rem;
  font-weight: 500;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.contact-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--clr-primary);
  color: var(--clr-primary);
}

.contact-link-icon {
  font-size: 1.3rem;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  text-align: center;
  padding: 32px 24px;
  color: var(--clr-text-muted);
  font-size: 0.85rem;
  border-top: 1px solid var(--clr-border);
}

/* ============================================================
   SCROLL ANIMATIONS
   ============================================================ */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .navbar {
    padding: 14px 20px;
  }

  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 70%;
    max-width: 300px;
    height: 100vh;
    flex-direction: column;
    background: var(--clr-surface);
    padding: 80px 32px 32px;
    gap: 24px;
    box-shadow: var(--shadow-lg);
    transition: right var(--transition);
  }

  .nav-links.open {
    right: 0;
  }

  .hero {
    flex-direction: column;
    text-align: center;
    padding: 120px 24px 60px;
    gap: 40px;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero-description {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-photo {
    width: 200px;
    height: 200px;
  }

  .section {
    padding: 72px 0;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }

  .interests-grid {
    grid-template-columns: 1fr 1fr;
  }

  .contact-links {
    flex-direction: column;
    align-items: center;
  }
}

@media (max-width: 480px) {
  .interests-grid {
    grid-template-columns: 1fr;
  }
}
