:root {
  --bg: #07090a;
  --bg-2: #0c1213;
  --panel: rgba(18, 26, 28, 0.72);
  --border: #1c2a2c;
  --text: #cdd6d4;
  --dim: #6c807e;
  --green: #2bff9c;
  --cyan: #5ef1ff;
  --glow: rgba(43, 255, 156, 0.35);
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--mono);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

.bg-grid {
  position: fixed;
  inset: -50%;
  z-index: -2;
  background-image:
    linear-gradient(rgba(43, 255, 156, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(43, 255, 156, 0.04) 1px, transparent 1px);
  background-size: 44px 44px;
  animation: drift 40s linear infinite;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 30%, transparent 75%);
}
@keyframes drift {
  from { transform: translateY(0); }
  to { transform: translateY(44px); }
}

.scanlines {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.012) 0px,
    rgba(255, 255, 255, 0.012) 1px,
    transparent 1px,
    transparent 3px
  );
}

.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px clamp(20px, 5vw, 64px);
  background: rgba(7, 9, 10, 0.7);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.brand { text-decoration: none; font-weight: 700; font-size: 0.95rem; }
.brand-prompt { color: var(--green); }
.brand-path { color: var(--cyan); }
.cursor-blink { color: var(--green); animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

.nav-links { display: flex; flex-wrap: wrap; gap: clamp(12px, 2.5vw, 28px); justify-content: flex-end; }
.nav-links a {
  color: var(--dim);
  text-decoration: none;
  font-size: 0.85rem;
  position: relative;
  transition: color 0.2s ease;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -4px;
  width: 0; height: 1px;
  background: var(--green);
  transition: width 0.25s ease;
}
.nav-links a:hover { color: var(--green); }
.nav-links a:hover::after { width: 100%; }

main { max-width: 980px; margin: 0 auto; padding: 0 clamp(20px, 5vw, 40px); }
.section { padding: clamp(56px, 9vw, 96px) 0 12px; }
.section-title {
  font-size: clamp(1.4rem, 3.5vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 10px;
}
.hash { color: var(--green); }
.section-sub { color: var(--dim); max-width: 720px; margin-bottom: 28px; font-size: 0.95rem; }

.hero {
  min-height: 88vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 22px;
  padding-top: 24px;
}

.terminal {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(43,255,156,0.04);
  overflow: hidden;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: rgba(0,0,0,0.25);
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.red { background: #ff5f6e; }
.dot.yellow { background: #ffd152; }
.dot.green { background: #2bff9c; }
.terminal-title { margin-left: 8px; color: var(--dim); font-size: 0.8rem; }
.terminal-body { padding: 18px 18px 22px; font-size: 0.92rem; }
.line { margin: 0 0 8px; word-break: break-word; }
.prompt { color: var(--green); font-weight: 700; }
.dir { color: var(--cyan); }
.out { color: var(--text); padding-left: 0.25rem; }
.out.dim { color: var(--dim); }
.terminal a { color: var(--cyan); text-decoration: none; }
.terminal a:hover { text-decoration: underline; }

.hero-meta { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--dim);
  font-size: 0.8rem;
  background: rgba(18, 26, 28, 0.5);
}
.pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 0 var(--glow);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 var(--glow); }
  70% { box-shadow: 0 0 0 8px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

.redact-note {
  color: var(--dim);
  font-size: 0.85rem;
  max-width: 720px;
  border-left: 2px solid var(--green);
  padding-left: 14px;
}
.redact-note a { color: var(--cyan); }

.skill-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.card {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px;
  background: rgba(18, 26, 28, 0.45);
}
.card h3 { color: var(--green); font-size: 1rem; margin-bottom: 8px; }
.card p, .card ul { color: var(--dim); font-size: 0.88rem; }

.timeline { display: flex; flex-direction: column; gap: 22px; }
.job {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 20px;
  background: rgba(18, 26, 28, 0.45);
}
.job-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}
.job h3 { font-size: 1rem; color: var(--text); }
.when { color: var(--cyan); font-size: 0.82rem; }
.where { color: var(--dim); font-size: 0.88rem; margin-bottom: 10px; }
.where a { color: var(--cyan); text-decoration: none; }
.where a:hover { text-decoration: underline; }
.job ul, .project-card ul { padding-left: 1.1rem; color: var(--dim); font-size: 0.88rem; }
.job li, .project-card li { margin-bottom: 6px; }

.project-card .cta {
  display: inline-block;
  margin-top: 14px;
  color: var(--green);
  text-decoration: none;
  font-weight: 700;
}
.project-card .cta:hover { text-decoration: underline; }

.contact { padding-bottom: 40px; }

.footer {
  border-top: 1px solid var(--border);
  padding: 24px clamp(20px, 5vw, 64px) 40px;
  color: var(--dim);
  font-size: 0.82rem;
  text-align: center;
}
.footer a { color: var(--cyan); text-decoration: none; }

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 640px) {
  .nav { flex-direction: column; align-items: flex-start; }
  .hero { min-height: auto; padding: 28px 0 10px; }
}
