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

:root {
  --bg: #0a0a0b;
  --bg-alt: #111113;
  --surface: #18181b;
  --surface-hover: #1f1f23;
  --border: #27272a;
  --text: #fafafa;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --accent: #818cf8;
  --accent-dim: rgba(129, 140, 248, 0.1);
  --accent-glow: rgba(129, 140, 248, 0.15);
  --gradient: linear-gradient(135deg, #818cf8, #c084fc);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --mono: 'JetBrains Mono', monospace;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

ul { list-style: none; }

/* ===== CURSOR GLOW ===== */
.cursor-glow {
  position: fixed;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

/* ===== NAVIGATION ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  transition: all 0.3s var(--ease);
  backdrop-filter: blur(0px);
}

.nav.scrolled {
  background: rgba(10, 10, 11, 0.85);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 2rem;
}

.nav-inner {
  max-width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1rem;
}

.nav-logo {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  gap: 2.5rem;
}

.nav-links a {
  font-size: 0.95rem;
  color: var(--text-secondary);
  transition: color 0.2s ease;
  font-weight: 500;
}

.nav-links a:hover {
  color: var(--text);
}

.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(--text-secondary);
  border-radius: 2px;
  transition: all 0.3s var(--ease);
}

.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem 0;
  max-width: 1200px;
  margin: 0 auto;
}

.mobile-menu a {
  font-size: 1rem;
  color: var(--text-secondary);
  padding: 0.5rem 0;
  transition: color 0.2s ease;
}

.mobile-menu a:hover {
  color: var(--text);
}

.mobile-menu.open {
  display: flex;
}

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 6rem 2rem 4rem;
}

.hero-content {
  max-width: 800px;
  text-align: center;
}

.hero-badge {
  display: inline-block;
  padding: 0.4rem 1rem;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-dim);
  border: 1px solid rgba(129, 140, 248, 0.2);
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-title .line {
  display: block;
}

.accent-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto 2.5rem;
  line-height: 1.7;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-bottom: 4rem;
}

.btn {
  padding: 0.75rem 1.75rem;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s var(--ease);
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--gradient);
  color: white;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(129, 140, 248, 0.3);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--text);
  transform: translateY(-2px);
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 4rem;
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  font-family: var(--mono);
}

.stat-plus {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero-scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
}

.scroll-line {
  width: 1px;
  height: 60px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.5); transform-origin: top; }
  50% { opacity: 1; transform: scaleY(1); }
}

/* ===== SECTIONS ===== */
.section {
  padding: 6rem 2rem;
}

.section-alt {
  background: var(--bg-alt);
}

.container {
  max-width: 1100px;
  margin: 0 auto;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 3.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-number {
  font-family: var(--mono);
  font-size: 1rem;
  color: var(--accent);
  font-weight: 500;
}

/* ===== TIMELINE ===== */
.timeline {
  position: relative;
  padding-left: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--border);
}

.timeline-item {
  position: relative;
  margin-bottom: 2.5rem;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  left: -2rem;
  top: 1.5rem;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--accent);
  z-index: 1;
  transition: all 0.3s ease;
}

.timeline-item:hover .timeline-dot {
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent-glow);
}

.timeline-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.75rem;
  transition: all 0.4s var(--ease);
}

.timeline-card:hover {
  border-color: rgba(129, 140, 248, 0.3);
  transform: translateX(4px);
  box-shadow: 0 4px 40px rgba(0, 0, 0, 0.3);
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
  gap: 1rem;
}

.timeline-header h3 {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.company {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
}

.location {
  color: var(--text-muted);
}

.acquired {
  color: var(--text-muted);
  font-size: 0.8rem;
}

.date {
  font-size: 0.8rem;
  font-family: var(--mono);
  color: var(--text-muted);
  white-space: nowrap;
  padding-top: 0.15rem;
}

.timeline-list {
  margin-bottom: 1rem;
}

.timeline-list li {
  position: relative;
  padding-left: 1.25rem;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.timeline-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.6em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.6;
}

.timeline-list li strong {
  color: var(--text);
  font-weight: 500;
}

.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.timeline-tags span {
  font-size: 0.75rem;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  background: var(--accent-dim);
  color: var(--accent);
  font-weight: 500;
}

/* ===== SKILLS ===== */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.25rem;
}

.skill-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.75rem;
  transition: all 0.4s var(--ease);
}

.skill-card:hover {
  border-color: rgba(129, 140, 248, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.3);
}

.skill-icon {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
}

.skill-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.skill-tags span {
  font-size: 0.8rem;
  padding: 0.3rem 0.7rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  border: 1px solid var(--border);
  transition: all 0.2s ease;
}

.skill-tags span:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-dim);
}

/* ===== PROJECTS ===== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1.25rem;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  transition: all 0.4s var(--ease);
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-card:hover {
  border-color: rgba(129, 140, 248, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.3);
}

.project-card:hover::before {
  opacity: 1;
}

.project-type {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.project-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.project-card p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
  flex-grow: 1;
  margin-bottom: 1rem;
}

.project-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.project-tag {
  font-size: 0.75rem;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-muted);
}

/* ===== EDUCATION ===== */
.education-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
}

.education-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.5rem;
  gap: 1rem;
}

.education-header h3 {
  font-size: 1.2rem;
  font-weight: 600;
}

.education-spec {
  color: var(--accent);
  font-size: 0.9rem;
  margin-top: 0.2rem;
}

.education-highlights {
  display: flex;
  gap: 3rem;
}

.highlight {
  display: flex;
  flex-direction: column;
}

.highlight-number {
  font-size: 1.75rem;
  font-weight: 700;
  font-family: var(--mono);
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.highlight-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

/* ===== TEST SCORES ===== */
.subsection-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-top: 2.5rem;
  margin-bottom: 1.25rem;
  color: var(--text);
}

.test-scores {
  display: flex;
  gap: 1.25rem;
}

.score-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  flex: 1;
  transition: all 0.3s var(--ease);
}

.score-card:hover {
  border-color: rgba(129, 140, 248, 0.3);
  transform: translateY(-2px);
}

.score-name {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.score-value {
  font-size: 2rem;
  font-weight: 700;
  font-family: var(--mono);
  color: var(--text);
  line-height: 1;
  margin-bottom: 0.4rem;
}

.score-date {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ===== CONTACT ===== */
.contact-content {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.contact-text {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  line-height: 1.7;
}

.contact-links {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.5rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  font-size: 0.95rem;
  color: var(--text-secondary);
  transition: all 0.3s var(--ease);
  width: fit-content;
}

.contact-item:hover {
  border-color: var(--accent);
  color: var(--text);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.contact-icon {
  font-size: 1.2rem;
}

.contact-location {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ===== FOOTER ===== */
.footer {
  padding: 2rem;
  text-align: center;
  border-top: 1px solid var(--border);
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ===== LINKS ===== */
.company-link {
  color: var(--text-secondary);
  transition: color 0.2s ease;
  border-bottom: 1px solid transparent;
}

.company-link:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.project-link {
  color: inherit;
  transition: color 0.2s ease;
}

.project-link:hover {
  color: var(--accent);
}

/* ===== REVEAL ANIMATIONS ===== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
.timeline-item.reveal { transition-delay: 0.05s; }
.skill-card.reveal:nth-child(1) { transition-delay: 0s; }
.skill-card.reveal:nth-child(2) { transition-delay: 0.08s; }
.skill-card.reveal:nth-child(3) { transition-delay: 0.16s; }
.skill-card.reveal:nth-child(4) { transition-delay: 0.24s; }
.skill-card.reveal:nth-child(5) { transition-delay: 0.32s; }
.project-card.reveal:nth-child(1) { transition-delay: 0s; }
.project-card.reveal:nth-child(2) { transition-delay: 0.08s; }
.project-card.reveal:nth-child(3) { transition-delay: 0.16s; }
.project-card.reveal:nth-child(4) { transition-delay: 0.24s; }
.project-card.reveal:nth-child(5) { transition-delay: 0.32s; }
.project-card.reveal:nth-child(6) { transition-delay: 0.40s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 640px) {
  .nav-links { display: none; }
  .nav-toggle { display: flex; }

  .hero { padding: 5rem 1.5rem 3rem; }
  .hero-stats { gap: 2rem; }
  .hero-cta { flex-direction: column; align-items: center; }

  .section { padding: 4rem 1.5rem; }
  .section-title { font-size: 1.5rem; margin-bottom: 2.5rem; }

  .timeline { padding-left: 1.5rem; }
  .timeline-dot { left: -1.5rem; }
  .timeline-header { flex-direction: column; gap: 0.25rem; }

  .skills-grid { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }

  .education-header { flex-direction: column; gap: 0.25rem; }
  .education-highlights { gap: 2rem; }
}

@media (min-width: 641px) and (max-width: 768px) {
  .nav-links { gap: 1rem; }
  .nav-links a { font-size: 0.8rem; }
}

@media (max-width: 480px) {
  .hero-title { font-size: 2rem; }
  .hero-stats { flex-direction: column; gap: 1.5rem; }
  .stat-number { font-size: 1.5rem; }
}

/* ===== SELECTION ===== */
::selection {
  background: rgba(129, 140, 248, 0.3);
  color: var(--text);
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg);
}

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}
