/* ===== Variables ===== */
:root {
  --bg: #0c0a09;
  --bg-alt: #1c1917;
  --surface: #292524;
  --surface-hover: #33302e;
  --border: #44403c;
  --text: #e7e5e4;
  --text-muted: #a8a29e;
  --accent: #e8762a;
  --accent-soft: #f59e0b;
  --accent-glow: rgba(232, 118, 42, 0.12);
  --accent-secondary: #f59e0b;
  --radius: 12px;
  --radius-sm: 8px;
  --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --max-width: 1100px;
}

/* ===== Reset ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { max-width: 100%; display: block; }
.code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--accent-glow);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--accent-soft);
}

/* ===== Navigation ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(12, 10, 9, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition);
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.5px;
}
.accent { color: var(--accent); }
.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition);
  position: relative;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); }
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }

/* Language Toggle */
.lang-toggle {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 4px 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: border-color var(--transition);
}
.lang-toggle:hover { border-color: var(--accent); }
.lang-option {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  transition: color var(--transition);
}
.lang-option.active { color: var(--accent); }
.lang-separator { color: var(--text-muted); font-size: 12px; }

/* Hamburger */
.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 28px;
  height: 20px;
  position: relative;
  z-index: 1001;
}
.nav-hamburger span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--text);
  transition: var(--transition);
}
.nav-hamburger span:nth-child(1) { top: 0; }
.nav-hamburger span:nth-child(2) { top: 9px; }
.nav-hamburger span:nth-child(3) { top: 18px; }
.nav-hamburger.active span:nth-child(1) { top: 9px; transform: rotate(45deg); }
.nav-hamburger.active span:nth-child(2) { opacity: 0; }
.nav-hamburger.active span:nth-child(3) { top: 9px; transform: rotate(-45deg); }

/* Mobile Menu */
.mobile-menu {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(12, 10, 9, 0.95);
  backdrop-filter: blur(20px);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}
.mobile-menu.open { display: flex; }
.mobile-menu a {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-muted);
  transition: color var(--transition);
}
.mobile-menu a:hover { color: var(--accent); }

/* ===== Hero ===== */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 24px 60px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(ellipse at 50% 50%, var(--accent-glow) 0%, transparent 50%);
  animation: heroGlow 8s ease-in-out infinite alternate;
}
@keyframes heroGlow {
  0% { transform: translate(-10%, -10%) scale(1); }
  100% { transform: translate(10%, 10%) scale(1.1); }
}
.hero-content { position: relative; z-index: 1; }
.hero-greeting {
  font-size: 16px;
  font-weight: 500;
  color: var(--accent);
  margin-bottom: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.hero-name {
  font-size: clamp(36px, 7vw, 64px);
  font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1.1;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--text) 0%, var(--text-muted) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-title {
  font-size: clamp(18px, 3vw, 24px);
  font-weight: 400;
  color: var(--text-muted);
  margin-bottom: 20px;
}
.hero-subtitle {
  font-family: var(--font-mono);
  font-size: 15px;
  color: var(--accent-soft);
  margin-bottom: 36px;
}
.hero-cta {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-bottom: 40px;
}
.btn {
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  transition: all var(--transition);
  cursor: pointer;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
}
.btn-primary:hover {
  background: var(--accent-soft);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(232, 118, 42, 0.3);
}
.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}
.hero-socials {
  display: flex;
  gap: 20px;
  justify-content: center;
}
.hero-socials a {
  color: var(--text-muted);
  transition: all var(--transition);
}
.hero-socials a:hover {
  color: var(--accent);
  transform: translateY(-3px);
}

/* Scroll indicator */
.hero-scroll {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
}
.scroll-indicator {
  width: 24px;
  height: 40px;
  border: 2px solid var(--border);
  border-radius: 12px;
  position: relative;
}
.scroll-indicator::after {
  content: '';
  width: 4px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollDown 1.5s ease-in-out infinite;
}
@keyframes scrollDown {
  0%, 100% { opacity: 1; transform: translateX(-50%) translateY(0); }
  50% { opacity: 0.3; transform: translateX(-50%) translateY(12px); }
}

/* ===== Sections ===== */
.section { padding: 100px 24px; }
.section-alt { background: var(--bg-alt); }
.container { max-width: var(--max-width); margin: 0 auto; }
.section-title {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 48px;
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 60px;
  height: 3px;
  background: var(--accent);
  border-radius: 2px;
}

/* ===== About ===== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 48px;
  align-items: start;
}
.about-text p {
  color: var(--text-muted);
  margin-bottom: 16px;
  font-size: 15px;
  line-height: 1.75;
}
.about-highlights {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.highlight-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
  transition: border-color var(--transition);
}
.highlight-card:hover {
  border-color: var(--accent);
}
.highlight-tag {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  text-transform: lowercase;
  letter-spacing: 1px;
  margin-bottom: 4px;
}
.highlight-number {
  display: block;
  font-size: 28px;
  font-weight: 800;
  color: var(--accent);
  font-family: var(--font-mono);
}
.highlight-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  display: block;
}

/* ===== Timeline ===== */
.timeline {
  position: relative;
  padding-left: 48px;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--border);
}
.timeline-item {
  position: relative;
  margin-bottom: 40px;
}
.timeline-item:last-child { margin-bottom: 0; }
.timeline-version {
  position: absolute;
  left: -40px;
  top: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}
.timeline-version.current {
  color: var(--accent);
}
.timeline-version.edu {
  color: var(--accent-soft);
}
.timeline-content {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: border-color var(--transition);
}
.timeline-item:first-child .timeline-content {
  border-left: 3px solid var(--accent);
}
.timeline-content:hover { border-color: var(--accent); }
.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
}
.timeline-header h3 {
  font-size: 18px;
  font-weight: 700;
}
.timeline-company {
  font-size: 14px;
  color: var(--accent-soft);
  margin-top: 2px;
}
.timeline-date {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
  white-space: nowrap;
}
.timeline-content ul {
  margin-top: 8px;
}
.timeline-content li {
  color: var(--text-muted);
  font-size: 14px;
  padding-left: 16px;
  position: relative;
  margin-bottom: 8px;
}
.timeline-content li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.6;
}
.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 16px;
}
.timeline-tags span {
  font-size: 11px;
  font-weight: 500;
  padding: 3px 10px;
  border-radius: 20px;
  background: var(--accent-glow);
  color: var(--accent-soft);
  border: 1px solid rgba(232, 118, 42, 0.2);
}
.timeline-note {
  color: var(--text-muted);
  font-size: 14px;
  font-style: italic;
}

/* ===== Projects ===== */
.projects-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: all var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
}
.project-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 20px rgba(232, 118, 42, 0.08) inset;
}
.project-card.featured {
  grid-column: 1 / -1;
  border-color: var(--accent);
  background: linear-gradient(135deg, var(--surface) 0%, rgba(232, 118, 42, 0.05) 100%);
}
.project-featured-inner {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 24px;
  align-items: start;
}
.project-featured-left h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 10px;
}
.project-spec {
  font-family: var(--font-mono);
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.spec-row {
  display: flex;
  gap: 12px;
}
.spec-key {
  color: var(--text-muted);
  min-width: 48px;
}
.spec-val {
  color: var(--accent-soft);
}
.project-lang {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: lowercase;
  margin-bottom: 12px;
  display: block;
}
.project-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 3px 10px;
  border-radius: 20px;
}
.project-header {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-bottom: 8px;
  color: var(--text-muted);
}
.project-stars {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--accent-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}
.project-stars::before {
  content: '';
  display: inline-block;
  width: 14px;
  height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23f59e0b' viewBox='0 0 24 24'%3E%3Cpath d='M12 2l3.09 6.26L22 9.27l-5 4.87 1.18 6.88L12 17.77l-6.18 3.25L7 14.14 2 9.27l6.91-1.01L12 2z'/%3E%3C/svg%3E") no-repeat center;
  background-size: contain;
}
.project-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}
.project-card p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
}
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 16px;
}
.project-tags span {
  font-size: 11px;
  font-weight: 500;
  padding: 3px 10px;
  border-radius: 20px;
  background: var(--accent-glow);
  color: var(--accent-soft);
  border: 1px solid rgba(232, 118, 42, 0.2);
}

/* ===== Skills ===== */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.skill-category {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.skill-category h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 16px;
  color: var(--text);
}
.skill-bars { display: flex; flex-direction: column; gap: 12px; }
.skill-bar-header {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 4px;
}
.skill-bar-header span:first-child { font-weight: 600; }
.skill-bar-header span:last-child { color: var(--text-muted); font-size: 11px; font-family: var(--font-mono); }
.skill-bar {
  height: 6px;
  background: var(--bg);
  border-radius: 3px;
  overflow: hidden;
}
.skill-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-soft));
  border-radius: 3px;
  width: 0 !important;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.skill-bar-fill.animated {
  width: var(--target-width) !important;
}
.skill-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.skill-list li {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-muted);
  padding-left: 16px;
  position: relative;
}
.skill-list li::before {
  content: '\2014';
  position: absolute;
  left: 0;
  color: var(--border);
}
.skill-list.highlight li {
  color: var(--accent-soft);
}
.skill-list.highlight li::before {
  color: var(--accent);
}

/* ===== Contact ===== */
.contact-container { text-align: center; }
.contact-text {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 40px;
  line-height: 1.7;
}
.contact-links {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 500px;
  margin: 0 auto;
}
.contact-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid transparent;
  border-radius: var(--radius);
  transition: all var(--transition);
  color: var(--text-muted);
}
.contact-card:hover {
  border-left-color: var(--accent);
  color: var(--accent-soft);
}
.contact-card svg { flex-shrink: 0; }
.contact-card span { font-size: 14px; font-weight: 500; }

/* ===== Footer ===== */
.footer {
  text-align: center;
  padding: 32px 24px;
  border-top: 1px solid var(--border);
}
.footer p {
  font-size: 13px;
  color: var(--text-muted);
  font-family: var(--font-mono);
}

/* ===== Animations ===== */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-hamburger { display: block; }
  .hero { padding: 100px 20px 60px; }
  .hero-cta { flex-direction: column; align-items: center; }
  .about-grid { grid-template-columns: 1fr; }
  .about-highlights { grid-template-columns: 1fr 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .project-featured-inner { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: 1fr; }
  .timeline-header { flex-direction: column; gap: 4px; }
  .section { padding: 60px 20px; }
  .section-title { font-size: 26px; }
}
