/* ── Reset & base ─────────────────────────────────────────────────────────── */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg:          #0d1117;
  --surface:     #161b22;
  --surface2:    #1c2330;
  --border:      #30363d;
  --accent:      #2dd4bf;   /* teal */
  --accent-dim:  #134e4a;
  --text:        #e6edf3;
  --text-muted:  #8b949e;
  --text-subtle: #6e7681;
  --tag-bg:      #1e2d3d;
  --tag-text:    #79c0ff;
  --radius:      8px;
  --radius-sm:   4px;
  --font:        -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

html {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  scroll-behavior: smooth;
}

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

/* ── Layout ───────────────────────────────────────────────────────────────── */

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.content {
  flex: 1;
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}

/* ── Top navigation ───────────────────────────────────────────────────────── */

.site-nav {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-inner {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 1.5rem;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
}
.nav-link:hover { color: var(--text); background: var(--surface2); text-decoration: none; }
.nav-link--active { color: var(--accent); }
.nav-link--active:hover { color: var(--accent); }

.nav-social {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-social-link {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--text-muted);
  padding: 0.3rem 0.6rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  transition: color 0.15s, background 0.15s;
}
.nav-social-link:hover { color: var(--accent); background: var(--surface2); text-decoration: none; }

.nav-social-label {
  font-size: 0.8rem;
  font-weight: 500;
}

/* ── Header ───────────────────────────────────────────────────────────────── */

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 2.5rem 1.5rem;
}

.header-inner {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.profile-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border);
  flex-shrink: 0;
}

.name {
  font-size: 2.4rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--text);
  line-height: 1.1;
}

.title {
  margin-top: 0.35rem;
  font-size: 1.05rem;
  color: var(--accent);
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.slogan {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-subtle);
  font-style: italic;
  letter-spacing: 0.3px;
}

.header-contact {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: flex-end;
}

.contact-link {
  font-size: 0.9rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: color 0.15s;
}
.contact-link:hover { color: var(--accent); text-decoration: none; }

.contact-icon {
  font-size: 0.85rem;
  color: var(--text-subtle);
}

/* ── Section ──────────────────────────────────────────────────────────────── */

.section {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.section-title {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-subtle);
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border);
}

/* ── Summary ──────────────────────────────────────────────────────────────── */

.summary {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 70ch;
}

/* ── Timeline / Projects ──────────────────────────────────────────────────── */

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.project {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 0 1.5rem;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border);
  position: relative;
}
.project:last-child { border-bottom: none; }

.project-meta {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding-top: 0.1rem;
}

.project-period {
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.project-location {
  font-size: 0.78rem;
  color: var(--text-subtle);
}

.project-body {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.project-header {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.project-role {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
}

.project-company {
  font-size: 0.88rem;
  color: var(--text-muted);
}
.project-company::before { content: "@ "; color: var(--text-subtle); }

.project-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.65;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.2rem;
}

.tag {
  font-size: 0.72rem;
  background: var(--tag-bg);
  color: var(--tag-text);
  border: 1px solid #1d3a5a;
  border-radius: var(--radius-sm);
  padding: 0.15rem 0.55rem;
  font-weight: 500;
  letter-spacing: 0.2px;
}

/* ── Skills ───────────────────────────────────────────────────────────────── */

.skill-groups {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}

.skill-group {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.skill-group-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.skill-dots {
  display: flex;
  gap: 3px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border);
  display: inline-block;
}
.dot--filled { background: var(--accent); }

.skill-group-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.skill-chip {
  font-size: 0.82rem;
  background: var(--surface2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.22rem 0.7rem;
  transition: border-color 0.15s, color 0.15s;
}
.skill-chip:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ── Education ────────────────────────────────────────────────────────────── */

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

.edu-degree {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
}

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

.edu-period {
  font-size: 0.82rem;
  color: var(--accent);
  margin-top: 0.2rem;
  font-weight: 500;
}

/* ── Certifications ───────────────────────────────────────────────────────── */

.certs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.cert {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  transition: border-color 0.15s;
}
.cert:hover { border-color: var(--accent-dim); }

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

.cert-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.35;
}

.cert-year {
  font-size: 0.75rem;
  color: var(--accent);
  font-weight: 500;
  white-space: nowrap;
}

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

.cert-detail {
  font-size: 0.78rem;
  color: var(--text-subtle);
  line-height: 1.5;
  margin-top: 0.15rem;
}

/* ── Languages ────────────────────────────────────────────────────────────── */

.languages {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.language-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}

.lang-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.lang-proficiency {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ── Footer ───────────────────────────────────────────────────────────────── */

.site-footer {
  text-align: center;
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--text-subtle);
}

/* ── Responsive ───────────────────────────────────────────────────────────── */

@media (max-width: 640px) {
  .name { font-size: 1.75rem; }

  .nav-social-label { display: none; }

  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  .header-contact { align-items: flex-start; }

  .project {
    grid-template-columns: 1fr;
    gap: 0.4rem;
  }

  .project-period {
    font-size: 0.75rem;
  }

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