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

:root {
  --bg: #0A0F1E;
  --surface: #0F1629;
  --border: #1E2A45;
  --accent: #00C896;
  --accent-blue: #3B82F6;
  --text: #E8EDF5;
  --text-muted: #8A97B0;
  --font-display: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius: 10px;
  --nav-h: 64px;
  --section-pad: 96px;
  --transition: 0.25s ease;
}

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

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

/* ===== SKIP LINK ===== */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--accent);
  color: var(--bg);
  padding: 0.5rem 1rem;
  border-radius: 0 0 var(--radius) var(--radius);
  font-weight: 600;
  font-family: var(--font-body);
  z-index: 9999;
  text-decoration: none;
  transition: top var(--transition);
}
.skip-link:focus {
  top: 0;
}

/* ===== NAV ===== */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
}

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

.nav-logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--accent);
  letter-spacing: 0.05em;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  transition: color var(--transition);
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--accent);
}

/* ===== LANG SWITCHER ===== */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: 1.5rem;
}

.lang-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  padding: 4px 6px;
  border-radius: 4px;
  transition: color var(--transition);
}

.lang-btn[aria-pressed="true"] {
  color: var(--accent);
}

.lang-btn:hover {
  color: var(--text);
}

.lang-divider {
  color: var(--border);
  font-size: 0.75rem;
  user-select: none;
}

/* ===== REVEAL ANIMATION ===== */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ===== HERO ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: calc(var(--nav-h) + 3rem) 2rem 4rem;
  background:
    radial-gradient(ellipse 60% 50% at 70% 40%, rgba(0, 200, 150, 0.06) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 20% 70%, rgba(59, 130, 246, 0.05) 0%, transparent 70%),
    var(--bg);
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 4rem;
  align-items: center;
}

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
  transition-delay: 0.05s;
}

.hero-name {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 0.5rem;
  transition-delay: 0.1s;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 0.5rem;
  transition-delay: 0.15s;
}

.hero-location {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  transition-delay: 0.2s;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.hero-location svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.hero-links {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  transition-delay: 0.25s;
}

.hero-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.4rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}

.hero-links a:hover,
.hero-links a:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
  background: rgba(0, 200, 150, 0.06);
}

.hero-links a svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.hero-summary {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.75;
  max-width: 560px;
  transition-delay: 0.3s;
}

/* ===== TERMINAL ===== */
.hero-terminal {
  background: #070C1A;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(0, 200, 150, 0.08);
  transition-delay: 0.35s;
}

.terminal-bar {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.75rem 1rem;
  background: #0D1425;
  border-bottom: 1px solid var(--border);
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot-red    { background: #FF5F56; }
.dot-yellow { background: #FFBD2E; }
.dot-green  { background: #27C93F; }

.terminal-title {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-left: auto;
}

.terminal-body {
  padding: 1.5rem;
  min-height: 160px;
}

.terminal-line {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}

.terminal-prompt {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 0.9rem;
  flex-shrink: 0;
  padding-top: 2px;
}

.terminal-cmd {
  font-family: var(--font-mono);
  color: var(--text);
  font-size: 0.88rem;
  line-height: 1.6;
  white-space: pre-wrap;
}

.terminal-cursor {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 0.88rem;
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

/* ===== SECTIONS ===== */
.section {
  padding: var(--section-pad) 2rem;
}

.section-alt {
  background: rgba(15, 22, 41, 0.6);
}

.section-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  margin-bottom: 3rem;
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.section-num {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--accent);
}

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

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), rgba(0,200,150,0.1));
  border-radius: 2px;
}

/* Company group (multiple roles) */
.company-group {
  position: relative;
  margin-bottom: 2.5rem;
  padding-left: 2rem;
}

.company-group-label {
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.company-group-bracket {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.company-group-bracket .exp-card {
  border-radius: 0;
  border: none;
  border-bottom: 1px solid var(--border);
  margin: 0;
}

.company-group-bracket .exp-card:last-child {
  border-bottom: none;
}

/* Single role card */
.exp-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 2rem;
  margin-left: 2rem;
  position: relative;
  border-left: 3px solid transparent;
  transition: border-left-color var(--transition), box-shadow var(--transition);
}

.exp-card:hover {
  border-left-color: var(--accent);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.timeline-dot {
  position: absolute;
  left: -2.6rem;
  top: 1.4rem;
  width: 10px;
  height: 10px;
  background: var(--accent);
  border-radius: 50%;
  border: 2px solid var(--bg);
  flex-shrink: 0;
}

.company-group .timeline-dot {
  left: -0.6rem;
}

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

.exp-role {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

.exp-period {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  white-space: nowrap;
  flex-shrink: 0;
  padding: 0.2rem 0.6rem;
  background: rgba(0, 200, 150, 0.08);
  border-radius: 4px;
}

.exp-company {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.exp-location {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
  opacity: 0.7;
}

.exp-highlights {
  list-style: none;
  margin-bottom: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.exp-highlights li {
  font-size: 0.875rem;
  color: var(--text-muted);
  padding-left: 1.2rem;
  position: relative;
  line-height: 1.55;
}

.exp-highlights li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.75rem;
  top: 0.05em;
}

.exp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--accent);
  background: rgba(0, 200, 150, 0.08);
  border: 1px solid rgba(0, 200, 150, 0.2);
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  transition: background var(--transition), filter var(--transition);
}

.tag:hover {
  background: rgba(0, 200, 150, 0.15);
  filter: brightness(1.1);
}

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

.skill-category {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: border-color var(--transition);
}

.skill-category:hover {
  border-color: rgba(0, 200, 150, 0.3);
}

.skill-cat-title {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-blue);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.skill-cat-title::before {
  content: '';
  width: 18px;
  height: 2px;
  background: var(--accent-blue);
  border-radius: 2px;
  flex-shrink: 0;
}

.skill-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.skill-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text);
  background: #1E2A45;
  padding: 0.3rem 0.7rem;
  border-radius: 5px;
  border: 1px solid rgba(255,255,255,0.05);
  transition: background var(--transition), filter var(--transition);
}

.skill-badge:hover {
  background: #263552;
  filter: brightness(1.15);
}

/* ===== EDUCATION ===== */
.edu-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.edu-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  border-left: 3px solid var(--accent-blue);
  transition: box-shadow var(--transition);
}

.edu-card:hover {
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.edu-section-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--accent-blue);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.edu-degree {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
}

.edu-institution {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.edu-period {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  opacity: 0.7;
}

.cert-name {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
}

.cert-issuer {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* ===== LANGUAGES ===== */
.lang-list {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.lang-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.lang-name {
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 600;
}

.lang-level {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ===== CONTACT ===== */
.contact-inner {
  text-align: center;
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}

.contact-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 1rem;
  font-weight: 500;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  transition: color var(--transition), border-color var(--transition), background var(--transition);
}

.contact-link:hover,
.contact-link:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
  background: rgba(0, 200, 150, 0.06);
}

.contact-link svg {
  width: 20px !important;
  height: 20px !important;
}

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

/* ===== NOSCRIPT ===== */
.noscript-msg {
  position: fixed;
  inset: 0;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  font-size: 1.1rem;
  color: var(--text-muted);
  z-index: 9999;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .hero-terminal {
    max-width: 480px;
  }
}

@media (max-width: 768px) {
  :root {
    --section-pad: 64px;
  }

  .nav-links {
    gap: 1.25rem;
  }

  .nav-links a {
    font-size: 0.8rem;
  }

  .hero {
    padding: calc(var(--nav-h) + 2rem) 1.25rem 3rem;
  }

  .section {
    padding: var(--section-pad) 1.25rem;
  }

  .edu-grid {
    grid-template-columns: 1fr;
  }

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

  .exp-card {
    margin-left: 1.5rem;
  }

  .timeline-dot {
    left: -2rem;
  }
}

@media (max-width: 480px) {
  .nav-links {
    gap: 0.9rem;
  }
  .nav-links li:nth-child(n+4) {
    display: none;
  }
  .hero-terminal {
    display: none;
  }
}
