/* ── Reset & base ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0d0d0d;
  --surface:   #161616;
  --border:    #242424;
  --text:      #e8e8e8;
  --muted:     #888;
  --orange:    #ff6b2b;
  --lime:      #c8f000;
  --font:      -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --mono:      "SF Mono", "Fira Code", "Consolas", monospace;
}

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg);
  background-image:
    /* dot grid */
    radial-gradient(circle, rgba(255,255,255,0.06) 1px, transparent 1px),
    /* orange glow — top left */
    radial-gradient(ellipse 55% 45% at 5% 10%, rgba(255, 107, 43, 0.10) 0%, transparent 70%),
    /* lime glow — bottom right */
    radial-gradient(ellipse 50% 40% at 95% 90%, rgba(200, 240, 0, 0.07) 0%, transparent 70%);
  background-size: 28px 28px, 100% 100%, 100% 100%;
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.7;
}

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

ul { list-style: none; }

/* ── Typography helpers ───────────────────────────────────── */
.accent-orange { color: var(--orange); }
.accent-lime   { color: var(--lime); }

/* ── Layout ───────────────────────────────────────────────── */
.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

section { padding: 6rem 0; }

/* ── Nav ──────────────────────────────────────────────────── */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: rgba(13, 13, 13, 0.85);
  backdrop-filter: blur(10px);
}

nav {
  max-width: 960px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--orange);
  font-family: var(--mono);
}

nav ul {
  display: flex;
  gap: 2rem;
}

nav a {
  font-size: 0.875rem;
  color: var(--muted);
  transition: color 0.2s;
  letter-spacing: 0.03em;
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: transform 0.2s, opacity 0.2s;
}

.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 680px) {
  .nav-toggle { display: flex; }

  nav ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(13, 13, 13, 0.97);
    border-bottom: 1px solid var(--border);
    padding: 0.5rem 0;
  }

  nav ul.open { display: flex; }

  nav ul li a {
    display: block;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
  }
}

/* ── Button ───────────────────────────────────────────────── */
.btn {
  display: inline-block;
  margin-top: 2rem;
  padding: 0.75rem 1.75rem;
  border: 1px solid var(--orange);
  color: var(--orange);
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: background 0.2s, color 0.2s;
}

.btn:hover {
  background: var(--orange);
  color: var(--bg);
}

/* ── Hero ─────────────────────────────────────────────────── */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
}

.hero-content {
  max-width: 960px;
  margin: 0 auto;
  width: 100%;
}

@keyframes typewriter {
  from { width: 0; }
  to   { width: 15ch; }
}

@keyframes blink {
  0%, 100% { border-color: var(--lime); }
  50%      { border-color: transparent; }
}

.hero-greeting {
  color: var(--lime);
  font-family: var(--mono);
  font-size: 1rem;
  margin-bottom: 0.5rem;
  letter-spacing: 0.04em;
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  border-right: 2px solid var(--lime);
  width: 0;
  animation:
    typewriter 1s steps(14) 0.3s forwards,
    blink      1.1s step-end 0.3s infinite;
}

#hero h1 {
  font-size: clamp(3rem, 9vw, 6rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.hero-tagline {
  margin-top: 1.25rem;
  font-size: 1.125rem;
  color: var(--muted);
  max-width: 480px;
}

/* ── About ────────────────────────────────────────────────── */
#about { border-top: 1px solid var(--border); }

h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 2.5rem;
  letter-spacing: -0.01em;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.about-text p + p { margin-top: 1rem; }
.about-text p { color: var(--muted); }

.about-skills h3 {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: 1rem;
  font-family: var(--mono);
}

.skill-list li {
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  color: var(--muted);
}

.skill-list li:last-child { border-bottom: none; }

/* ── Experience ───────────────────────────────────────────── */
#experience { border-top: 1px solid var(--border); }

.experience-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.experience-entry {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.2s;
}

.experience-entry:hover { border-color: var(--lime); }

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

.experience-header h3 {
  font-size: 1.1rem;
  font-weight: 600;
}

.experience-company {
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--lime);
  letter-spacing: 0.04em;
}

.experience-date {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
  white-space: nowrap;
}

.experience-entry > p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.6;
}

@media (max-width: 680px) {
  .experience-header { flex-direction: column; }
}

/* ── Education & Certifications ───────────────────────────── */
#education { border-top: 1px solid var(--border); }

.edu-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}

.edu-col-title {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.25rem;
  font-family: var(--mono);
}

.edu-entries {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.edu-entry {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.edu-entry-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}

.edu-entry h4 {
  font-size: 0.95rem;
  font-weight: 600;
}

.edu-institution {
  font-size: 0.8rem;
  color: var(--muted);
  display: block;
  margin-top: 0.2rem;
}

.edu-date {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
  white-space: nowrap;
}


.cert-list {
  display: flex;
  flex-direction: column;
}

.cert-entry {
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.cert-entry:first-child { border-top: 1px solid var(--border); }

.cert-name {
  font-size: 0.9rem;
  font-weight: 500;
}

.cert-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--muted);
  font-family: var(--mono);
}

@media (max-width: 680px) {
  .edu-grid { grid-template-columns: 1fr; }
}

/* ── Projects ─────────────────────────────────────────────── */
#projects { border-top: 1px solid var(--border); }

.project-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.2s, transform 0.2s;
  color: inherit;
  cursor: pointer;
}

.project-card:hover {
  border-color: var(--orange);
  transform: translateY(-3px);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.card-tag {
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lime);
  background: rgba(200, 240, 0, 0.08);
  padding: 0.2rem 0.6rem;
  border: 1px solid rgba(200, 240, 0, 0.2);
}

.card-links {
  display: flex;
  gap: 0.75rem;
}

.card-links a {
  color: var(--muted);
  font-size: 1.1rem;
  transition: color 0.2s;
}

.card-links a:hover { color: var(--orange); }

.project-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
}

.project-card p {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.6;
  flex: 1;
}

.tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.25rem;
}

.tech-stack li {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--muted);
  border: 1px solid var(--border);
  padding: 0.15rem 0.5rem;
}

/* ── Contact ──────────────────────────────────────────────── */
#contact { border-top: 1px solid var(--border); }

.contact-inner {
  text-align: center;
}

.contact-inner p {
  color: var(--muted);
  max-width: 480px;
  margin: 0 auto;
}

.social-links {
  margin-top: 2.5rem;
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.social-links a {
  font-size: 0.875rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  border-bottom: 1px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}

.social-links a:hover {
  color: var(--lime);
  border-color: var(--lime);
}

/* ── Legal pages ──────────────────────────────────────────── */
.legal-content h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
  color: var(--lime);
  font-family: var(--mono);
  letter-spacing: 0.03em;
}

.legal-content p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.7;
}

.legal-content a { color: var(--orange); }
.legal-content a:hover { text-decoration: underline; }

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

footer a {
  color: var(--muted);
  transition: color 0.2s;
}

footer a:hover { color: var(--text); }

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 680px) {
  .about-grid      { grid-template-columns: 1fr; }
  .project-grid    { grid-template-columns: 1fr; }

  nav ul           { gap: 1.25rem; }
}
