/* ============================================================
   ROOT VARIABLES & RESET
   ============================================================ */
:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #111118;
  --bg-card: #16161e;
  --bg-card-hover: #1c1c28;
  --text-primary: #f0eff5;
  --text-secondary: #8b8a99;
  --text-muted: #55546a;
  --accent-color: #7c6ef8;
  --accent-glow: rgba(124, 110, 248, 0.15);
  --accent-2: #e8c97a;
  --border: rgba(255,255,255,0.07);
  --border-hover: rgba(124, 110, 248, 0.4);
  --shadow: 0 4px 32px rgba(0,0,0,0.4);
  --shadow-lg: 0 8px 64px rgba(0,0,0,0.6);
  --radius: 16px;
  --radius-sm: 10px;
  --nav-height: 72px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg-primary: #f5f4fb;
  --bg-secondary: #eceaf5;
  --bg-card: #ffffff;
  --bg-card-hover: #f0effe;
  --text-primary: #0d0c1a;
  --text-secondary: #5c5a75;
  --text-muted: #a8a6be;
  --accent-color: #5a47e8;
  --accent-glow: rgba(90, 71, 232, 0.12);
  --border: rgba(0,0,0,0.08);
  --border-hover: rgba(90, 71, 232, 0.4);
  --shadow: 0 4px 32px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 64px rgba(0,0,0,0.12);
}

*, *::before, *::after {
  margin: 0; padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background var(--transition), color var(--transition);
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { display: block; max-width: 100%; }

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-color);
  margin-bottom: 24px;
}

.section-title {
  font-family: 'Syne', sans-serif;
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  line-height: 1.1;
  color: var(--text-primary);
  margin-bottom: 48px;
}

.section-title em {
  font-style: normal;
  color: var(--accent-color);
}

/* ============================================================
   LAYOUT
   ============================================================ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.section {
  padding: 120px 0;
}

.section-alt {
  background: var(--bg-secondary);
}

/* ============================================================
   SCROLL ANIMATIONS
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s cubic-bezier(0.4,0,0.2,1), transform 0.7s cubic-bezier(0.4,0,0.2,1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: transparent;
  transition: background var(--transition), backdrop-filter var(--transition), box-shadow var(--transition);
}

.navbar.scrolled {
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 var(--border);
}

[data-theme="light"] .navbar.scrolled {
  background: rgba(245, 244, 251, 0.85);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 32px;
  max-width: 1400px;
  margin: 0 auto;
}

.nav-logo {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  transition: color var(--transition);
}

.nav-logo:hover { color: var(--accent-color); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-secondary);
  padding: 6px 14px;
  border-radius: 8px;
  transition: color var(--transition), background var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
  background: var(--bg-card);
}

.nav-cta {
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: var(--accent-color);
  padding: 8px 20px;
  border-radius: 8px;
  margin-left: 8px;
  transition: opacity var(--transition), transform var(--transition);
}

.nav-cta:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.theme-toggle {
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  width: 36px;
  height: 36px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  margin-left: 8px;
  /* was: transition: all var(--transition); — narrowed to the properties
     that actually change on :hover (background, color, border-color), so
     the browser only tracks/interpolates those instead of every animatable
     property (transform, box-shadow, width, etc.) on every style recalc. */
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.theme-toggle:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--border-hover);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  /* Left as `all`: the open/active state for this element (turning bars into
     an X) isn't defined in this file, so I can't safely confirm every property
     that changes without risking a visual regression. See notes below. */
  transition: all var(--transition);
}

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 4px;
  padding: 16px 32px 24px;
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
}

.mobile-menu.open { display: flex; }

.mobile-link {
  padding: 10px 16px;
  color: var(--text-secondary);
  font-size: 15px;
  border-radius: 8px;
  /* was: transition: all var(--transition); — only color/background change on hover */
  transition: color var(--transition), background var(--transition);
}

.mobile-link:hover {
  color: var(--text-primary);
  background: var(--bg-card);
}

.mobile-link.cta {
  background: var(--accent-color);
  color: #fff;
  font-weight: 600;
  margin-top: 8px;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding-top: var(--nav-height);
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(124,110,248,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124,110,248,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse at 50% 50%, black 40%, transparent 80%);
}

.hero-glow {
  position: absolute;
  top: 20%;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(124,110,248,0.12) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 32px;
  flex: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 6px 16px;
  border-radius: 100px;
  margin-bottom: 32px;
}

.badge-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.85); }
}

.hero-title {
  font-family: 'Syne', sans-serif;
  font-size: clamp(48px, 8vw, 88px);
  font-weight: 800;
  line-height: 1.0;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 24px;
}

.hero-name {
  color: var(--accent-color);
  display: block;
}

.hero-role {
  font-family: 'DM Mono', monospace;
  font-size: 20px;
  color: var(--text-secondary);
  margin-bottom: 48px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.role-prefix {
  color: var(--accent-color);
}

.cursor {
  color: var(--accent-color);
  animation: blink 1s infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 64px;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 32px;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-num {
  font-family: 'Syne', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
  font-family: 'DM Mono', monospace;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

.hero-code-card {
  position: absolute;
  right: 80px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  animation: float 4s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(-50%) translateY(0px); }
  50% { transform: translateY(-50%) translateY(-12px); }
}

.code-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  width: 320px;
}

.code-card-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

.dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}

.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }

.code-card-title {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--text-muted);
  margin-left: 8px;
}

.code-card-body {
  padding: 20px;
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  line-height: 1.8;
  overflow: hidden;
}

.c-kw { color: #c792ea; }
.c-var { color: #82aaff; }
.c-key { color: #80cbc4; }
.c-str { color: #c3e88d; }
.c-bool { color: #f78c6c; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-color);
  color: #fff;
  font-weight: 600;
  font-size: 15px;
  padding: 14px 28px;
  border-radius: 10px;
  transition: all var(--transition);
  border: none;
  cursor: pointer;
}

.btn-primary svg {
  width: 18px;
  height: 18px;
}

.btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(124, 110, 248, 0.4);
}

.btn-arrow { font-style: normal; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 15px;
  padding: 13px 28px;
  border-radius: 10px;
  border: 1px solid var(--border);
  transition: all var(--transition);
  cursor: pointer;
}

.btn-secondary:hover {
  border-color: var(--border-hover);
  background: var(--bg-card);
  transform: translateY(-2px);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  color: var(--accent-color);
  font-weight: 600;
  font-size: 15px;
  padding: 14px 0;
  border: none;
  background: none;
  transition: all var(--transition);
  cursor: pointer;
  letter-spacing: 0.02em;
}

.btn-ghost:hover { opacity: 0.75; }

/* ============================================================
   ABOUT
   ============================================================ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.about-body {
  font-size: 17px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 20px;
}

.about-links {
  display: flex;
  gap: 16px;
  margin-top: 32px;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  transition: all var(--transition);
}

.social-link svg { width: 16px; height: 16px; }

.social-link:hover {
  color: var(--accent-color);
  border-color: var(--border-hover);
  background: var(--accent-glow);
}

.about-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.about-card-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
}

.about-card-item:last-child { border-bottom: none; }
.about-card-item:hover { background: var(--bg-card-hover); }

.aci-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.aci-value {
  font-size: 15px;
  color: var(--text-primary);
  font-weight: 500;
}

/* ============================================================
   EDUCATION
   ============================================================ */
.edu-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.edu-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  cursor: pointer;
  /* was: transition: all var(--transition); — narrowed to border-color,
     transform, box-shadow (the only properties :hover actually changes) */
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  position: relative;
  overflow: hidden;
}

.edu-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-color), transparent);
  opacity: 0;
  transition: opacity var(--transition);
}

.edu-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.edu-card:hover::before { opacity: 1; }

.edu-card-year {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.edu-card-icon {
  font-size: 28px;
  margin-bottom: 16px;
}

.edu-card-title {
  font-family: 'Syne', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.edu-card-inst {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 20px;
  line-height: 1.4;
}

.edu-card-score {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 20px;
}

.score-num {
  font-family: 'Syne', sans-serif;
  font-size: 32px;
  font-weight: 700;
  color: var(--accent-color);
}

.score-label {
  font-size: 13px;
  color: var(--text-muted);
}

.edu-card-cta, .timeline-cta, .project-cta, .ach-cta {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-color);
  letter-spacing: 0.02em;
  transition: opacity var(--transition);
}

.edu-card:hover .edu-card-cta { opacity: 0.7; }

/* ============================================================
   EXPERIENCE TIMELINE
   ============================================================ */
.timeline {
  position: relative;
  padding-left: 32px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, var(--accent-color), transparent);
}

.timeline-item {
  position: relative;
  margin-bottom: 48px;
  cursor: pointer;
}

.timeline-item:last-child { margin-bottom: 0; }

.timeline-dot {
  position: absolute;
  left: -39px;
  top: 6px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent-color);
  border: 3px solid var(--bg-primary);
  box-shadow: 0 0 0 1px var(--accent-color);
  transition: transform var(--transition);
}

.timeline-item:hover .timeline-dot {
  transform: scale(1.3);
}

.timeline-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 32px 28px;
  transition: all var(--transition);
  position: relative; /* 👈 REQUIRED */
}

.timeline-date {
  position: absolute;
  top: 24px;
  right: 28px;
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--text-muted);
}

.timeline-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.timeline-item:hover .timeline-content {
  border-color: var(--border-hover);
  transform: translateX(4px);
  box-shadow: var(--shadow);
}

.timeline-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.timeline-period {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--text-muted);
}

.timeline-badge {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
  padding: 2px 8px;
  border-radius: 100px;
}

.timeline-role {
  font-family: 'Syne', sans-serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.timeline-company {
  font-size: 14px;
  color: var(--accent-color);
  font-weight: 500;
  margin-bottom: 16px;
}

.timeline-bullets {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.timeline-bullets li {
  font-size: 14px;
  color: var(--text-secondary);
  padding-left: 16px;
  position: relative;
}

.timeline-bullets li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-size: 12px;
}

/* ============================================================
   SKILLS
   ============================================================ */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.skill-group {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: all var(--transition);
}

.skill-group:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow);
}

.skill-group-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-color);
  margin-bottom: 16px;
}

.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.skill-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 8px;
  /* was: transition: all var(--transition); — narrowed to the four
     properties that actually change on :hover */
  transition: border-color var(--transition), background var(--transition), color var(--transition), transform var(--transition);
  cursor: default;
}

.skill-chip:hover {
  border-color: var(--border-hover);
  background: var(--accent-glow);
  color: var(--accent-color);
  transform: translateY(-2px);
}

.skill-icon {
  font-size: 12px;
  font-family: 'DM Mono', monospace;
  color: var(--accent-color);
  min-width: 18px;
  text-align: center;
}

/* ============================================================
   PROJECTS
   ============================================================ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  cursor: pointer;
  /* was: transition: all var(--transition); — narrowed to border-color,
     transform, box-shadow (the ::after underline has its own explicit
     transition already, so it's unaffected either way) */
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.project-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-color), #e8c97a);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
}

.project-card:hover::after { transform: scaleX(1); }

.project-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.project-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.project-number {
  font-family: 'Syne', sans-serif;
  font-size: 13px;
  font-weight: 800;
  color: var(--text-muted);
  letter-spacing: 0.08em;
}

.project-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.stack-tag {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--accent-color);
  background: var(--accent-glow);
  border: 1px solid rgba(124,110,248,0.2);
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.06em;
}

.project-name {
  font-family: 'Syne', sans-serif;
  font-size: 19px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
  line-height: 1.3;
}

.project-summary {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 20px;
}

.project-cta {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-color);
  margin-top: auto;
  display: inline-block;
  transition: opacity var(--transition);
}

.project-card:hover .project-cta { opacity: 0.7; }

.project-title-row {
  display: flex;

  align-items: flex-start;
  justify-content: space-between;

  gap: 16px;

  margin-bottom: 12px;
}

@media (max-width: 480px) {
  .project-title-row {
    display: flex;
    
    align-items: flex-start;
    justify-content: space-between;
  }
}

/* ============================================================
   FEATURED PROJECT
   ============================================================ */

.featured-project {
  position: relative;
  overflow: hidden;

  background:
    linear-gradient(
      180deg,
      rgba(124,110,248,0.08) 0%,
      rgba(124,110,248,0.02) 100%
    ),
    var(--bg-card);

  border: 1px solid rgba(124,110,248,0.28);

  box-shadow:
    0 10px 40px rgba(124,110,248,0.08),
    0 0 0 1px rgba(124,110,248,0.08),
    inset 0 1px 0 rgba(255,255,255,0.04);

  transform-style: preserve-3d;
}

/* Animated glow orb */
.featured-project::before {
  content: '';

  position: absolute;

  width: 280px;
  height: 280px;

  top: -120px;
  right: -120px;

  border-radius: 50%;

  background:
    radial-gradient(
      circle,
      rgba(179, 170, 255, 0.22) 0%,
      transparent 70%
    );

  opacity: 0.9;

  pointer-events: none;

  animation: featuredFloat 8s ease-in-out infinite;
}

/* Top premium accent line */
.featured-project::after {
  content: '';

  position: absolute;

  top: 0;
  left: 24px;
  right: 24px;

  height: 1px;

  background:
    linear-gradient(
      90deg,
      transparent,
      rgba(124,110,248,0.9),
      rgba(232,201,122,0.8),
      transparent
    );
}

/* Hover interaction */
.featured-project:hover {
  transform:
    translateY(-10px)
    rotateX(2deg);

  border-color: rgba(124,110,248,0.5);

  box-shadow:
    0 18px 60px rgba(124,110,248,0.18),
    0 0 0 1px rgba(124,110,248,0.18),
    inset 0 1px 0 rgba(255,255,255,0.05);
}

/* Smooth ambient motion */
@keyframes featuredFloat {
  0%, 100% {
    transform: translateY(0px) translateX(0px);
  }

  50% {
    transform: translateY(18px) translateX(-12px);
  }
}

.featured-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 5px 10px;

  border-radius: 999px;

  font-family: 'DM Mono', monospace;
  font-size: 8px;
  font-weight: 600;

  letter-spacing: 0.3em;
  text-transform: uppercase;

  color: #ffffff;

  background:
    linear-gradient(
      135deg,
      rgba(124,110,248,1),
      rgba(160,145,255,1)
    );

  border: 1px solid rgba(255,255,255,0.08);

  box-shadow:
    0 6px 18px rgba(124,110,248,0.22);

  white-space: nowrap;

  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.featured-project:hover .featured-badge {
  transform: translateY(-1px);

  box-shadow:
    0 10px 24px rgba(124,110,248,0.32);
}


/* ============================================================
   ACHIEVEMENTS
   ============================================================ */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.achievement-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  cursor: pointer;
  /* was: transition: all var(--transition); — narrowed to border-color,
     transform, box-shadow, background (the only properties :hover changes) */
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition), background var(--transition);
}

.achievement-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  background: var(--bg-card-hover);
}

.ach-icon {
  font-size: 28px;
  margin-bottom: 16px;
}

.ach-title {
  font-family: 'Syne', sans-serif;
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.ach-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

.ach-cta {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-color);
}

/* ============================================================
   HIRE ME
   ============================================================ */
.hire-section {
  background: var(--bg-secondary);
  position: relative;
  overflow: hidden;
}

.hire-section::before {
  content: '';
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 600px;
  background: radial-gradient(ellipse at center, rgba(124,110,248,0.08) 0%, transparent 70%);
  pointer-events: none;
}

.hire-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.hire-title {
  font-family: 'Syne', sans-serif;
  font-size: clamp(36px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.15;
  color: var(--text-primary);
  margin-bottom: 24px;
}

.hire-title em { font-style: normal; color: var(--accent-color); }

.hire-body {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 36px;
}

.hire-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.contact-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
}

.contact-item:last-child { border-bottom: none; }
.contact-item:hover { background: var(--bg-card-hover); }

.contact-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.contact-value {
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
  transition: color var(--transition);
}

a.contact-value:hover { color: var(--accent-color); }

.contact-value.available {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #22c55e;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--bg-primary);
  border-top: 1px solid var(--border);
  padding: 48px 0;
}

.footer-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 32px;
}

.footer-logo {
  font-family: 'Syne', sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  margin-bottom: 8px;
}

.footer-tagline {
  font-size: 14px;
  color: var(--text-muted);
  font-style: italic;
}

.footer-right {
  display: flex;
  gap: 24px;
  align-items: center;
}

.footer-link {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color var(--transition);
}

.footer-link:hover { color: var(--accent-color); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  font-size: 13px;
  color: var(--text-muted);
}

/* ============================================================
   MODAL
   ============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  max-width: 680px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  position: relative;
  box-shadow: var(--shadow-lg);
  transform: scale(0.95) translateY(16px);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.modal-overlay.open .modal {
  transform: scale(1) translateY(0);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  /* was: transition: all var(--transition); — only color/background change */
  transition: color var(--transition), background var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover {
  color: var(--text-primary);
  background: var(--bg-card-hover);
}

.modal-content {
  padding: 40px;
}

.modal-section-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent-color);
  margin-bottom: 8px;
}

.modal-title {
  font-family: 'Syne', sans-serif;
  font-size: 26px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
  line-height: 1.2;
}

.modal-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 28px;
}

.modal-divider {
  height: 1px;
  background: var(--border);
  margin: 24px 0;
}

.modal-body p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 20px;
}

.modal-body h4 {
  font-family: 'Syne', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.modal-body ul {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.modal-body ul li {
  font-size: 14px;
  color: var(--text-secondary);
  padding-left: 20px;
  position: relative;
  line-height: 1.6;
}

.modal-body ul li::before {
  content: '↗';
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-size: 12px;
}

.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.modal-tag {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  color: var(--accent-color);
  background: var(--accent-glow);
  border: 1px solid rgba(124,110,248,0.2);
  padding: 4px 12px;
  border-radius: 6px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 28px;
}

.modal-impact {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 20px;
  margin-top: 20px;
}

.modal-impact-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-2);
  margin-bottom: 8px;
}

.modal-impact p {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 0;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .hero-code-card {
    display: none;
  }

  .about-grid, .hire-inner {
    grid-template-columns: 1fr;
    gap: 48px;
  }

  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .edu-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .container { padding: 0 20px; }
  .section { padding: 80px 0; }

  .nav-links { display: none; }
  .hamburger { display: flex; }

  .projects-grid, .edu-grid {
    grid-template-columns: 1fr;
  }

  .hero-content { padding: 60px 20px; }

  .hero-stats {
    gap: 20px;
  }

  .modal-content { padding: 28px 24px; }

  .footer-inner { flex-direction: column; gap: 24px; }

  /* NEW: let the date flow normally above the role instead of overlapping it */
  .timeline-date {
    position: static;
    display: block;
    margin-bottom: 12px;
  }
}

@media (max-width: 480px) {
  .hero-actions { flex-direction: column; }
  .hire-actions { flex-direction: column; }
  .hero-stats { gap: 16px; }
  .stat-num { font-size: 24px; }

  /* NEW: shrink hero title on small screens instead of floor-clamping at 48px */
  .hero-title {
    font-size: clamp(32px, 11vw, 48px);
    letter-spacing: -0.02em;
  }

  .hero-name {
    overflow-wrap: break-word;
    word-break: break-word;
  }

  /* NEW: make stacked hero buttons full-width and consistently sized */
  .hero-actions .btn-primary,
  .hero-actions .btn-secondary {
    width: 100%;
    justify-content: center;
  }
}