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

:root {
  --blue: #3b82f6;
  --blue-dark: #2563eb;
  --blue-light: #eff6ff;
  --navy: #0f172a;
  --text: #1e293b;
  --text-dim: #64748b;
  --text-muted: #94a3b8;
  --card: #ffffff;
  --border: rgba(148, 163, 184, 0.22);
  --radius-xl: 20px;
  --radius-lg: 14px;
  --radius-md: 10px;
  --shadow: 0 1px 3px rgba(0,0,0,0.04), 0 8px 32px rgba(59,130,246,0.07);
  --shadow-hover: 0 4px 24px rgba(59,130,246,0.16);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: linear-gradient(135deg, #eef1ff 0%, #f5f7ff 45%, #f0f4ff 100%);
  background-attachment: fixed;
  min-height: 100vh;
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
img { display: block; max-width: 100%; }
button { cursor: pointer; border: none; background: none; font: inherit; }

/* ===========================
   NAV
=========================== */
nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 62px;
  background: rgba(238, 241, 255, 0.88);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.nav-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3b82f6, #6366f1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.nav-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--navy);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.15rem;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-dim);
  padding: 0.4rem 0.8rem;
  border-radius: 8px;
  transition: color 0.2s, background 0.2s;
}
.nav-links a:hover { color: var(--navy); background: rgba(59,130,246,0.07); }
.nav-links a.active { color: var(--navy); font-weight: 600; }

.nav-cta {
  background: var(--navy) !important;
  color: #fff !important;
  padding: 0.45rem 1.15rem !important;
  border-radius: 50px !important;
  font-weight: 600 !important;
  margin-left: 0.5rem;
  transition: opacity 0.2s !important;
}
.nav-cta:hover { opacity: 0.82 !important; }

/* ===========================
   MAIN
=========================== */
main {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem;
}

/* ===========================
   SECTION HEADING
=========================== */
.section-eyebrow {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 0.35rem;
}

.section-heading {
  margin-bottom: 2.25rem;
}

.section-heading h2 {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.02em;
  margin-bottom: 0.35rem;
}

.section-heading p { font-size: 0.88rem; color: var(--text-dim); }

section { margin-bottom: 4.5rem; }

/* ===========================
   HERO
=========================== */
.hero-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2.5rem;
  align-items: center;
  padding: 2.4rem 2.5rem;
  justify-content: center;
  margin-bottom: 1.25rem;
  background: linear-gradient(135deg, #ffffff 55%, #eff3ff 100%);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.hero-card::after {
  content: '';
  position: absolute;
  right: -70px; top: -70px;
  width: 280px; height: 280px;
  background: radial-gradient(circle, rgba(99,102,241,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hero-photo {
  width: 185px;
  height: 225px;
  border-radius: 14px;
  object-fit: cover;
  object-position: top;
  box-shadow: 0 0 0 4px rgba(99,102,241,0.12), 0 8px 28px rgba(99,102,241,0.2);
  position: relative;
  z-index: 1;
}

.hero-content { position: relative; z-index: 1; }

.hero-status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--blue-light);
  border: 1px solid rgba(59,130,246,0.22);
  border-radius: 50px;
  padding: 0.28rem 0.9rem;
  font-size: 0.76rem;
  font-weight: 500;
  color: var(--blue);
  margin-bottom: 0.85rem;
}

.hero-status::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
  animation: pulse-dot 2.2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.75); }
}

.hero-name {
  font-size: 2.35rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: 0.5rem;
}

.hero-subtitle {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--blue);
  margin-bottom: 0.85rem;
}

.hero-bio {
  font-size: 0.875rem;
  color: var(--text-dim);
  line-height: 1.72;
  max-width: 510px;
  margin-bottom: 1.4rem;
}

.hero-actions { display: flex; gap: 0.65rem; flex-wrap: wrap; }

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--blue);
  color: #fff;
  padding: 0.55rem 1.3rem;
  border-radius: 50px;
  font-size: 0.86rem;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(59,130,246,0.35);
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 22px rgba(59,130,246,0.45); color: #fff; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: #fff;
  color: var(--navy);
  border: 1px solid var(--border);
  padding: 0.55rem 1.3rem;
  border-radius: 50px;
  font-size: 0.86rem;
  font-weight: 600;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-secondary:hover { transform: translateY(-2px); box-shadow: 0 4px 14px rgba(0,0,0,0.1); }

/* ===========================
   HOME CTA CARDS
=========================== */
.home-cta-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 4rem;
}

.home-cta-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.4rem 1.5rem;
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
  color: inherit;
}
.home-cta-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }

.home-cta-icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--blue-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--blue);
}
.home-cta-icon svg { width: 20px; height: 20px; }

.home-cta-text { flex: 1; }
.home-cta-title { font-weight: 700; font-size: 0.98rem; color: var(--navy); margin-bottom: 0.25rem; }
.home-cta-desc { font-size: 0.8rem; color: var(--text-dim); line-height: 1.5; }

.home-cta-arrow {
  position: absolute;
  top: 1.1rem; right: 1.2rem;
  width: 18px; height: 18px;
  color: var(--text-muted);
  transform: rotate(-45deg);
}

/* ===========================
   TIMELINE
=========================== */
.tl-list {
  position: relative;
}

.tl-list::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0; bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, transparent, rgba(59,130,246,0.22) 8%, rgba(59,130,246,0.22) 92%, transparent);
  transform: translateX(-50%);
  pointer-events: none;
}

.tl-row {
  display: grid;
  grid-template-columns: 1fr 80px 1fr;
  align-items: start;
  padding: 0.65rem 0;
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.tl-row.tl-visible { opacity: 1; transform: translateY(0); }

.tl-side { display: flex; }
.tl-side-left { justify-content: flex-end; padding-right: 1.5rem; }
.tl-side-right { padding-left: 1.5rem; }

.tl-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 1.1rem;
  gap: 0.3rem;
  z-index: 1;
}

.tl-dot {
  width: 13px; height: 13px;
  border-radius: 50%;
  background: var(--blue);
  border: 3px solid #eef1ff;
  box-shadow: 0 0 0 2px rgba(59,130,246,0.3);
  flex-shrink: 0;
}

.tl-date-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--blue);
  letter-spacing: 0.03em;
  margin-top: 0.35rem;
  white-space: nowrap;
}

/* Timeline Cards */
.tl-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 1.1rem 1.25rem;
  width: 100%;
  transition: transform 0.2s, box-shadow 0.2s;
}
.tl-clickable { cursor: pointer; }
.tl-card.tl-clickable:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }

.tl-card-top {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.tl-logo {
  width: 38px; height: 38px;
  border-radius: 10px;
  object-fit: contain;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  padding: 3px;
  flex-shrink: 0;
}

.tl-card-text { flex: 1; min-width: 0; }

.tl-name { font-weight: 700; font-size: 0.9rem; color: var(--navy); margin-bottom: 0.1rem; }
.tl-role { font-size: 0.78rem; color: var(--text-dim); margin-bottom: 0.1rem; }
.tl-location { font-size: 0.7rem; color: var(--text-muted); }
.tl-gpa { font-size: 0.7rem; color: var(--text-muted); margin-top: 0.1rem; }

.tl-expand-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.85rem;
  padding: 0.42rem 0.9rem;
  background: var(--blue-light);
  border-radius: 8px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--blue);
  transition: background 0.2s;
}
.tl-expand-btn:hover { background: #dbeafe; }
.tl-chevron { display: flex; align-items: center; transition: transform 0.3s; }
.tl-card.tl-expanded .tl-chevron { transform: rotate(180deg); }

/* Project detail panels */
.tl-projects-wrap { max-height: 0; overflow: hidden; transition: max-height 0.4s ease; }
.tl-projects-wrap.tl-projects-open { max-height: 5000px; }

.tl-projects {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  padding: 0.75rem 0 1.5rem;
}

.tl-project-detail {
  background: #f0f4ff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 1.1rem 1.25rem;
  display: flex;
  flex-direction: column;
}

.tl-project-detail .tl-project-links {
  margin-top: auto;
  padding-top: 0.75rem;
}

.tl-project-top {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.65rem;
}

.tl-project-name { font-size: 0.88rem; font-weight: 700; color: var(--navy); }
.tl-project-role { font-size: 0.76rem; color: var(--text-dim); }
.tl-project-date { font-size: 0.68rem; color: var(--text-muted); margin-top: 0.1rem; }

.tl-project-links { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.tl-project-link-btn {
  display: inline-block;
  color: var(--blue);
  font-size: 0.8rem;
  font-weight: 600;
  transition: opacity 0.2s;
}
.tl-project-link-btn:hover { opacity: 0.7; text-decoration: underline; }

.tl-project-text { font-size: 0.82rem; color: var(--text-dim); line-height: 1.55; margin: 0; }
.tl-project-text span { font-weight: 600; color: var(--text); }

/* Timeline Modal */
.tl-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,0.55);
  backdrop-filter: blur(5px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.tl-modal-overlay.tl-modal-visible { display: flex; }

.tl-modal {
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0,0,0,0.2);
  max-width: 520px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  padding: 2rem;
}

.tl-modal-close {
  position: absolute;
  top: 1rem; right: 1rem;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--text-dim);
  transition: background 0.2s;
}
.tl-modal-close:hover { background: #e2e8f0; color: var(--navy); }

.tl-modal-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding-right: 2rem;
}

.tl-modal-name { font-size: 1.1rem; font-weight: 700; color: var(--navy); }
.tl-modal-role { font-size: 0.84rem; color: var(--text-dim); margin-top: 0.15rem; }
.tl-modal-date { font-size: 0.77rem; color: var(--text-muted); margin-top: 0.1rem; }

.tl-modal-section { margin-top: 1.2rem; }
.tl-modal-section h4 {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.45rem;
}
.tl-modal-section p { font-size: 0.875rem; color: var(--text-dim); line-height: 1.68; }

/* ===========================
   SKILLS
=========================== */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.skills-category {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.4rem 1.5rem;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.skills-category.tl-visible { opacity: 1; transform: translateY(0); }

.skills-category h4 {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 0.9rem;
}

.skills-row { display: flex; flex-wrap: wrap; gap: 0.45rem; }

.skill-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 50px;
  padding: 0.3rem 0.75rem;
  font-size: 0.77rem;
  color: var(--text);
  font-weight: 500;
  transition: border-color 0.2s, background 0.2s;
}
.skill-chip:hover { border-color: rgba(59,130,246,0.3); background: var(--blue-light); }

.skill-icon { width: 15px; height: 15px; object-fit: contain; flex-shrink: 0; }

/* ===========================
   PAGE HEADER (inner pages)
=========================== */
.page-header {
  margin-bottom: 2.5rem;
}

.page-title {
  font-size: 2rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.025em;
  margin-bottom: 0.4rem;
}

.page-subtitle {
  font-size: 0.88rem;
  color: var(--text-dim);
  max-width: 580px;
  line-height: 1.6;
}

.page-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

/* ===========================
   PROJECTS GRID
=========================== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.project-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.22s, box-shadow 0.22s;
}
.project-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }

.project-thumb {
  width: 100%;
  height: 175px;
  background: linear-gradient(135deg, #e0e7ff, #c7d2fe);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--text-dim);
  font-size: 0.8rem;
}
.project-thumb img { width: 100%; height: 100%; object-fit: cover; }

.project-thumb-collage {
  width: 100%;
  height: 175px;
  display: flex;
  gap: 3px;
  overflow: hidden;
}
.project-thumb-collage img { flex: 1; height: 100%; object-fit: cover; }

.project-thumb-coming-soon {
  background: linear-gradient(135deg, #f0f4ff 0%, #e8eeff 100%);
  border-bottom: 1px dashed rgba(148,163,184,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-name,
.project-card-name {
  font-size: 0.87rem;
  font-weight: 700;
  color: var(--navy);
  padding: 0.9rem 1rem 0.35rem;
  line-height: 1.35;
}

.project-card-cta {
  padding: 0 1rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue);
}

.coming-soon-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px dashed rgba(148,163,184,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 220px;
  opacity: 0;
  transition: opacity 0.5s ease;
}
.coming-soon-card.tl-visible { opacity: 1; }

.coming-soon-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px dashed rgba(148,163,184,0.5);
  padding: 0.3rem 0.75rem;
  border-radius: 50px;
}

/* Project Modal */
.project-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,0.62);
  backdrop-filter: blur(6px);
  z-index: 150;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.project-modal-overlay.project-modal-visible { display: flex; }

.project-modal {
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0,0,0,0.22);
  width: 100%;
  max-width: 600px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.project-modal-close-btn {
  position: absolute;
  top: 0.85rem; right: 0.85rem;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: rgba(15,23,42,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--text-dim);
  z-index: 10;
  transition: background 0.2s;
}
.project-modal-close-btn:hover { background: rgba(15,23,42,0.15); color: var(--navy); }

.project-modal-body { overflow-y: auto; flex: 1; padding: 1.2rem 1.5rem 1.5rem; }

.project-slider {
  position: relative;
  background: #0f172a;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 1rem;
}

.project-slide {
  width: 100%;
  aspect-ratio: 16/9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.project-slide img { width: 100%; height: 100%; object-fit: contain; }
.project-slide-zoomable { cursor: zoom-in; }

.project-slide-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(15,23,42,0.55);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  z-index: 5;
  transition: background 0.2s;
}
.project-slide-arrow:hover { background: rgba(15,23,42,0.82); }
.project-slide-prev { left: 0.6rem; }
.project-slide-next { right: 0.6rem; }

.project-dots { display: flex; justify-content: center; gap: 0.4rem; margin-bottom: 1.1rem; }
.project-dot { width: 7px; height: 7px; border-radius: 50%; background: #cbd5e1; cursor: pointer; transition: background 0.2s, transform 0.2s; }
.project-dot.project-dot-active { background: var(--blue); transform: scale(1.3); }

.project-modal-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--blue);
  color: #fff;
  padding: 0.58rem 1.3rem;
  border-radius: 50px;
  font-size: 0.86rem;
  font-weight: 600;
  margin-bottom: 1.2rem;
  box-shadow: 0 4px 14px rgba(59,130,246,0.35);
  transition: transform 0.2s, box-shadow 0.2s;
}
.project-modal-link:hover { transform: translateY(-2px); box-shadow: 0 6px 22px rgba(59,130,246,0.45); color: #fff; }

.project-modal-name {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 0.65rem;
  letter-spacing: -0.01em;
}

.project-modal-summary {
  font-size: 0.86rem;
  color: var(--text-dim);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

.project-modal-section h4 {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.6rem;
}

.project-modal-tech { display: flex; flex-wrap: wrap; gap: 0.45rem; }

.project-tech-tag,
.tech-pill {
  background: var(--blue-light);
  color: var(--blue);
  border: 1px solid rgba(59,130,246,0.2);
  border-radius: 50px;
  padding: 0.25rem 0.75rem;
  font-size: 0.76rem;
  font-weight: 600;
}

.project-modal-note {
  background: #fefce8;
  border: 1px solid #fde68a;
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  font-size: 0.82rem;
  color: #92400e;
  line-height: 1.5;
  margin-bottom: 1.1rem;
}

/* Lightbox */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.93);
  z-index: 300;
  align-items: center;
  justify-content: center;
}
.lightbox-overlay.lightbox-visible { display: flex; }

.lightbox-img { max-width: 90vw; max-height: 88vh; object-fit: contain; border-radius: var(--radius-md); }

.lightbox-close {
  position: absolute;
  top: 1.2rem; right: 1.5rem;
  font-size: 2rem;
  color: rgba(255,255,255,0.85);
  transition: color 0.2s;
}
.lightbox-close:hover { color: #fff; }

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3rem;
  color: rgba(255,255,255,0.75);
  padding: 0 1.2rem;
  transition: color 0.2s;
}
.lightbox-arrow:hover { color: #fff; }
.lightbox-prev { left: 0; }
.lightbox-next { right: 0; }

/* ===========================
   CHEATSHEETS
=========================== */
.cheatsheets-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

.cheatsheet-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: transform 0.22s, box-shadow 0.22s;
}
.cheatsheet-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }

.cheatsheet-thumb {
  width: 100%;
  height: 155px;
  background: #f1f5f9;
  flex-shrink: 0;
  overflow: hidden;
}
.cheatsheet-thumb img { width: 100%; height: 100%; object-fit: cover; }

.cheatsheet-card-body { display: flex; flex-direction: column; flex: 1; }

.cheatsheet-name,
.cheatsheet-card-name { font-size: 0.88rem; font-weight: 700; color: var(--navy); padding: 0.9rem 1rem 0.2rem; }
.cheatsheet-summary,
.cheatsheet-card-summary { font-size: 0.77rem; color: var(--text-dim); padding: 0 1rem; line-height: 1.5; flex: 1; }

.cheatsheet-card-cta {
  display: block;
  padding: 0.65rem 1rem 0.7rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--blue);
  margin-top: 0.35rem;
  transition: opacity 0.2s;
}
.cheatsheet-card:hover .cheatsheet-card-cta { opacity: 0.7; }

.cheatsheet-coming-soon {
  min-height: 230px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.77rem;
  color: var(--text-muted);
  font-weight: 500;
  cursor: default;
}

.cheatsheet-download-all {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--blue);
  color: #fff;
  padding: 0.55rem 1.2rem;
  border-radius: 50px;
  font-size: 0.84rem;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(59,130,246,0.3);
  transition: transform 0.2s, box-shadow 0.2s;
}
.cheatsheet-download-all:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(59,130,246,0.4); color: #fff; }
.cheatsheet-download-all-disabled { opacity: 0.45; pointer-events: none; }

/* Cheatsheet Modal */
.cs-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,0.62);
  backdrop-filter: blur(6px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.cs-modal-overlay.cs-modal-visible { display: flex; }

.cs-modal {
  background: var(--card);
  border-radius: var(--radius-xl);
  box-shadow: 0 24px 60px rgba(0,0,0,0.22);
  width: 100%;
  max-width: 820px;
  height: 88vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.cs-modal-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 1.4rem;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.cs-modal-titles { flex: 1; min-width: 0; }
.cs-modal-name { font-size: 0.95rem; font-weight: 700; color: var(--navy); }
.cs-modal-summary { font-size: 0.77rem; color: var(--text-dim); margin-top: 0.12rem; }

.cs-modal-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--blue);
  color: #fff;
  padding: 0.45rem 1rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity 0.2s;
}
.cs-modal-download-btn:hover { opacity: 0.85; color: #fff; }

.cs-modal-close {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--text-dim);
  flex-shrink: 0;
  transition: background 0.2s;
}
.cs-modal-close:hover { background: #e2e8f0; color: var(--navy); }

.cs-modal-iframe { flex: 1; border: none; width: 100%; }

.cs-modal-mobile-msg {
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 2.5rem 1.5rem;
  text-align: center;
  color: var(--text-dim);
}
.cs-modal-mobile-msg p { font-size: 0.9rem; line-height: 1.6; }
.cs-mobile-open-btn {
  display: inline-block;
  background: var(--blue);
  color: #fff;
  padding: 0.6rem 1.5rem;
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 600;
  transition: opacity 0.2s;
}
.cs-mobile-open-btn:hover { opacity: 0.85; color: #fff; }

/* ===========================
   CONTACT
=========================== */
.contact-wrap { max-width: 560px; margin: 0 auto; }
.contact-wrap .section-eyebrow { text-align: center; }
.contact-wrap .page-title { text-align: center; }
.contact-wrap .page-subtitle { text-align: center; margin: 0 auto 2rem; }

.contact-card {
  background: var(--card);
  border-radius: var(--radius-xl);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  padding: 2rem;
  margin-bottom: 1.5rem;
}

.contact-field { margin-bottom: 1.1rem; }

.contact-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--navy);
  margin-bottom: 0.4rem;
}

.contact-input {
  width: 100%;
  padding: 0.65rem 0.9rem;
  border: 1px solid #e2e8f0;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  font-family: inherit;
  color: var(--text);
  background: #f8fafc;
  outline: none;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.contact-input:focus {
  border-color: var(--blue);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(59,130,246,0.12);
}

.contact-textarea { resize: vertical; min-height: 130px; }

.contact-submit {
  width: 100%;
  padding: 0.75rem;
  background: var(--blue);
  color: #fff;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 700;
  font-family: inherit;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(59,130,246,0.35);
  transition: transform 0.2s, box-shadow 0.2s;
}
.contact-submit:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(59,130,246,0.45); }
.contact-submit:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.contact-success {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem;
  background: #f0fdf4;
  border-radius: var(--radius-md);
  border: 1px solid #bbf7d0;
}
.contact-success svg { width: 36px; height: 36px; color: #16a34a; flex-shrink: 0; }
.contact-success-title { font-weight: 700; color: #15803d; margin-bottom: 0.2rem; }
.contact-success-sub { font-size: 0.82rem; color: #16a34a; }

.contact-alt-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  font-size: 0.84rem;
  color: var(--text-dim);
}
.contact-alt-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--blue);
  font-weight: 600;
  transition: opacity 0.2s;
}
.contact-alt-links a:hover { opacity: 0.75; }

/* ===========================
   FOOTER
=========================== */
footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
  margin-top: 3rem;
}

.footer-columns { display: flex; gap: 3rem; margin-bottom: 1.5rem; }

.footer-col h4 {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.7rem;
}
.footer-col a { display: block; font-size: 0.83rem; color: var(--text-dim); margin-bottom: 0.38rem; transition: color 0.2s; }
.footer-col a:hover { color: var(--navy); }

.footer-copyright { font-size: 0.77rem; color: var(--text-muted); padding-bottom: 1.5rem; }
.footer-copyright-center { text-align: center; padding: 1rem 0 1.25rem; }

/* CTA Footer Card */
.footer-cta-card {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
  background: linear-gradient(to right, #cdd5ee 0%, #f2f5ff 45%, #dce8ff 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  text-align: center;
  padding: 3.5rem 2.5rem;
  margin-bottom: 0;
}
.footer-cta-heading {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}
.footer-cta-card.tl-visible { opacity: 1; transform: translateY(0); }
.footer-cta-accent { color: var(--blue); }
.footer-cta-sub {
  font-size: 0.9rem;
  color: var(--text-dim);
  max-width: 400px;
  margin: 0 auto 1.75rem;
  line-height: 1.6;
}
.footer-cta-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}
.footer-cta-btn-primary {
  background: var(--blue);
  color: #fff;
  padding: 0.6rem 1.5rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  transition: opacity 0.2s;
}
.footer-cta-btn-primary:hover { opacity: 0.85; color: #fff; }
.footer-cta-btn-secondary {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: #fff;
  color: var(--navy);
  border: 1px solid var(--border);
  padding: 0.6rem 1.5rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  transition: box-shadow 0.2s;
}
.footer-cta-btn-secondary:hover { box-shadow: var(--shadow-hover); color: var(--navy); }

/* ===========================
   MOBILE — MUST REMAIN LAST
=========================== */
/* Hamburger button — hidden on desktop */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 8px;
  transition: background 0.2s;
}
.nav-hamburger:hover { background: rgba(59,130,246,0.08); }
.nav-hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile dropdown menu */
.nav-mobile-menu {
  display: none;
  position: fixed;
  top: 62px;
  left: 0; right: 0;
  background: rgba(238,241,255,0.97);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
  flex-direction: column;
  padding: 0.5rem 1rem 1rem;
  z-index: 49;
}
.nav-mobile-menu.open { display: flex; }
.nav-mobile-menu a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-dim);
  padding: 0.7rem 0.5rem;
  border-bottom: 1px solid var(--border);
  transition: color 0.2s;
}
.nav-mobile-menu a:last-child { border-bottom: none; }
.nav-mobile-menu a:hover, .nav-mobile-menu a.active { color: var(--navy); font-weight: 600; }

@media (max-width: 720px) {
  nav { padding: 0 1rem; position: sticky; }
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }

  main { padding: 1.5rem 1rem 4rem; }

  /* Hero */
  .hero-card {
    grid-template-columns: 1fr;
    gap: 1.4rem;
    padding: 1.6rem 1.25rem;
    text-align: center;
  }
  .hero-photo { width: 110px; height: 135px; margin: 0 auto; }
  .hero-name { font-size: 1.7rem; }
  .hero-status { margin: 0 auto 0.85rem; }
  .hero-bio { font-size: 0.83rem; }
  .hero-actions { justify-content: center; }

  /* CTA row */
  .home-cta-row { grid-template-columns: 1fr; }

  /* Timeline — left-side vertical line */
  .tl-list::before { left: 16px; transform: none; }
  .tl-row {
    display: block;
    padding: 0.4rem 0 0.4rem 40px;
    position: relative;
  }
  .tl-center {
    position: absolute;
    left: 0; top: 1rem;
    padding: 0;
    flex-direction: column;
    align-items: center;
    width: 32px;
  }
  .tl-side-left { padding: 0; justify-content: flex-start; margin-bottom: 0.5rem; }
  .tl-side-right { padding: 0; justify-content: flex-start; }
  .tl-side-left:empty, .tl-side-right:empty { display: none; margin: 0; }

  /* Sub-project cards */
  .tl-projects { grid-template-columns: 1fr; }
  .tl-projects-wrap { margin-left: 40px; }

  /* Projects */
  .projects-grid { grid-template-columns: 1fr; }

  /* Project modal — sheet from bottom */
  .project-modal-overlay { padding: 0; align-items: flex-end; }
  .project-modal {
    max-width: 100%;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    max-height: 92dvh;
  }
  .project-modal-close-btn {
    position: fixed;
    top: 1rem; right: 1rem;
    z-index: 200;
    width: 40px; height: 40px;
    font-size: 1.35rem;
    background: var(--navy);
    color: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
  }

  /* Cheatsheets */
  .cheatsheets-grid { grid-template-columns: 1fr 1fr; }
  .cs-modal-overlay { padding: 0; }
  .cs-modal { max-width: 100%; height: 100dvh; border-radius: 0; }

  /* Skills */
  .skills-grid { grid-template-columns: 1fr 1fr; }

  /* Page title row */
  .page-title-row { flex-direction: column; }

  /* Lightbox */
  .lightbox-arrow { font-size: 2rem; padding: 0 0.5rem; }

  /* Footer */
  .footer-columns { flex-direction: column; gap: 1.5rem; }
}

@media (max-width: 480px) {
  .cheatsheets-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: 1fr; }
  .hero-name { font-size: 1.5rem; }
  .page-title { font-size: 1.65rem; }
}
