/* ── Variables ─────────────────────────────────────────────── */
:root {
  --primary:       #1a2f5e;
  --primary-hover: #243f80;
  --accent:        #2563eb;
  --bg:            #ffffff;
  --bg-alt:        #f2f6ff;
  --bg-dark:       #0f1e3d;
  --text:          #1e293b;
  --text-muted:    #64748b;
  --border:        #dde5f0;
  --tag-bg:        #e8eef8;
  --tag-text:      #1a2f5e;
  --shadow-sm:     0 2px 8px rgba(26,47,94,.07);
  --shadow-md:     0 6px 24px rgba(26,47,94,.11);
  --shadow-lg:     0 12px 40px rgba(26,47,94,.15);
  --radius:        12px;
  --radius-sm:     8px;
  --transition:    0.25s ease;
  --max-w:         1100px;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* ── Container ──────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
}
.btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}
.btn-outline:hover { background: var(--primary); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow-md); }

/* ── Navbar ─────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--transition);
}
.navbar.scrolled { box-shadow: var(--shadow-md); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.nav-logo {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.5px;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-links a {
  font-size: .9rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
}
.nav-links a:hover { color: var(--primary); }
.btn-nav {
  background: var(--primary) !important;
  color: #fff !important;
  padding: 8px 18px;
  border-radius: 8px;
  font-weight: 600 !important;
}
.btn-nav:hover { background: var(--primary-hover) !important; }
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
  transition: var(--transition);
}

/* ── Hero ───────────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 96px 0 64px;
  background: linear-gradient(135deg, #f2f6ff 0%, #ffffff 60%);
}
.hero-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
}
.hero-text { flex: 1; }
.hero-greeting {
  font-size: .95rem;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: .05em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.hero-name {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 800;
  color: var(--primary);
  line-height: 1.1;
  letter-spacing: -1.5px;
  margin-bottom: 10px;
}
.hero-role {
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 20px;
}
.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.hero-tags span {
  background: var(--tag-bg);
  color: var(--tag-text);
  font-size: .8rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
}
.hero-location {
  font-size: .9rem;
  color: var(--text-muted);
  margin-bottom: 28px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Profile photo */
.hero-photo-wrap {
  flex-shrink: 0;
  width: clamp(220px, 28vw, 320px);
  height: clamp(220px, 28vw, 320px);
  border-radius: 50%;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 4px solid var(--border);
  position: relative;
}
.hero-photo { width: 100%; height: 100%; object-fit: cover; }
.initials-fallback {
  display: none;
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  font-size: 4rem;
  font-weight: 800;
  align-items: center;
  justify-content: center;
  letter-spacing: -2px;
}

/* ── Sections ───────────────────────────────────────────────── */
.section { padding: 88px 0; }
.bg-alt { background: var(--bg-alt); }
.section-title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.5px;
  margin-bottom: 48px;
  position: relative;
  padding-bottom: 14px;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 48px; height: 4px;
  background: var(--accent);
  border-radius: 2px;
}
.section-title.light { color: #fff; }
.section-title.light::after { background: rgba(255,255,255,.5); }

/* ── Section subtitle ───────────────────────────────────────── */
.section-subtitle {
  color: var(--text-muted);
  font-size: .95rem;
  margin-top: -32px;
  margin-bottom: 36px;
  max-width: 600px;
}

/* ── About ──────────────────────────────────────────────────── */
.about-body {
  max-width: 760px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.about-body p { font-size: 1.05rem; color: var(--text); line-height: 1.8; }

/* ── Timeline ───────────────────────────────────────────────── */
.timeline { display: flex; flex-direction: column; gap: 40px; position: relative; }
.timeline::before {
  content: '';
  position: absolute;
  left: 15px; top: 8px; bottom: 8px;
  width: 2px;
  background: var(--border);
}
.timeline-item { display: flex; gap: 32px; position: relative; }
.timeline-dot {
  flex-shrink: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 2px var(--primary);
  margin-top: 4px;
  z-index: 1;
}
.timeline-card {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 32px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition);
}
.timeline-card:hover { box-shadow: var(--shadow-md); }
.timeline-meta { margin-bottom: 16px; }
.timeline-meta h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}
.company-name {
  display: block;
  font-size: .9rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 2px;
}
.tenure {
  display: block;
  font-size: .85rem;
  color: var(--text-muted);
}
.timeline-intro {
  margin-bottom: 20px;
  color: var(--text-muted);
  font-size: .95rem;
}
.inner-project {
  background: var(--bg-alt);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 14px 18px;
  margin-bottom: 14px;
}
.inner-project h4 {
  font-size: .95rem;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 6px;
}
.inner-project p { font-size: .9rem; color: var(--text); line-height: 1.7; }
.bullet-list { margin: 16px 0; padding-left: 4px; display: flex; flex-direction: column; gap: 6px; }
.bullet-list li {
  font-size: .9rem;
  color: var(--text);
  padding-left: 16px;
  position: relative;
}
.bullet-list li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: .8rem;
}

/* ── Tags ───────────────────────────────────────────────────── */
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}
.tag-row span {
  background: var(--tag-bg);
  color: var(--tag-text);
  font-size: .78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 20px;
}

/* ── Projects ───────────────────────────────────────────────── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.project-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.project-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.project-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.project-card-top h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1.3;
}
.project-card p { font-size: .9rem; color: var(--text); line-height: 1.7; flex: 1; }
.live-pill {
  display: inline-block;
  background: #d1fae5;
  color: #065f46;
  font-size: .72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
  transition: var(--transition);
}
.live-pill:hover { background: #a7f3d0; }
.amazon-pill {
  display: inline-block;
  background: #fff3e0;
  color: #c45c00;
  font-size: .72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ── Skills ─────────────────────────────────────────────────── */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.skill-group {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: var(--shadow-sm);
}
.skill-group h3 {
  font-size: .85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

/* ── Education ──────────────────────────────────────────────── */
.edu-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 32px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 640px;
}
.edu-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
}
.edu-note {
  font-size: .9rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ── Contact ────────────────────────────────────────────────── */
.contact-section {
  background: var(--bg-dark);
  color: #fff;
}
.contact-inner { text-align: center; }
.contact-intro {
  color: rgba(255,255,255,.7);
  font-size: 1.05rem;
  margin-bottom: 40px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
  max-width: 800px;
  margin: 0 auto;
}
.contact-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  color: rgba(255,255,255,.85);
  font-size: .9rem;
  transition: var(--transition);
  text-align: left;
}
.contact-item:hover {
  background: rgba(255,255,255,.12);
  color: #fff;
  transform: translateY(-2px);
}
.contact-icon {
  font-size: 1.1rem;
  width: 36px; height: 36px;
  background: rgba(255,255,255,.1);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-style: normal;
  font-weight: 700;
}

/* ── Footer ─────────────────────────────────────────────────── */
.footer {
  background: #080f1f;
  color: rgba(255,255,255,.4);
  text-align: center;
  padding: 20px;
  font-size: .85rem;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 768px) {
  .nav-links { display: none; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0; background: #fff; padding: 20px 24px 24px; gap: 16px; border-bottom: 1px solid var(--border); box-shadow: var(--shadow-md); }
  .nav-links.open { display: flex; }
  .nav-toggle { display: flex; }
  .hero-inner { flex-direction: column-reverse; text-align: center; }
  .hero-tags { justify-content: center; }
  .hero-actions { justify-content: center; }
  .hero-photo-wrap { width: 200px; height: 200px; }
  .timeline::before { display: none; }
  .timeline-item { flex-direction: column; gap: 12px; }
  .timeline-dot { display: none; }
  .timeline-card { padding: 20px; }
  .section { padding: 64px 0; }
}

@media (max-width: 480px) {
  .projects-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .hero-name { letter-spacing: -1px; }
}
