@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@0,300;0,400;0,600;1,300&family=IBM+Plex+Sans:ital,wght@0,300;0,400;0,600;0,700;1,300&display=swap');

/* ─── TOKENS ─────────────────────────────────────── */
:root {
  --bg:       #0d1117;
  --surface:  #161b22;
  --surface2: #1c2128;
  --border:   #30363d;
  --accent:   #58a6ff;
  --green:    #3fb950;
  --red:      #f78166;
  --purple:   #d2a8ff;
  --orange:   #ffa657;
  --text:     #e6edf3;
  --muted:    #8b949e;
}

/* ─── RESET ──────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 15px; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 1rem;
  line-height: 1.75;
  overflow-x: hidden;
}

::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* ─── SKIP LINK ──────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -40px; left: 0;
  background: var(--accent);
  color: var(--bg);
  padding: 8px 16px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  border-radius: 0 0 6px 0;
  z-index: 9999;
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus { top: 0; }

/* ─── NAV ────────────────────────────────────────── */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(13,17,23,0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  height: 58px;
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 58px;
  gap: 32px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.brand-mark {
  width: 30px; height: 30px;
  background: rgba(88,166,255,0.12);
  border: 1px solid rgba(88,166,255,0.35);
  border-radius: 5px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.05em;
}

.brand-text {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.02em;
}

.site-nav {
  display: flex;
  gap: 4px;
  align-items: center;
}

.nav-link {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 6px 12px;
  border-radius: 4px;
  transition: color 0.2s, background 0.2s;
}

.nav-link:hover { color: var(--text); background: rgba(255,255,255,0.04); }

.nav-link.active {
  color: var(--accent);
  background: rgba(88,166,255,0.1);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 10px;
  cursor: pointer;
  color: var(--muted);
}

.hamburger,
.hamburger::before,
.hamburger::after {
  display: block;
  width: 18px; height: 2px;
  background: var(--muted);
  border-radius: 1px;
  position: relative;
  transition: transform 0.2s;
}
.hamburger::before,
.hamburger::after {
  content: '';
  position: absolute;
  left: 0;
}
.hamburger::before { top: -5px; }
.hamburger::after  { top:  5px; }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ─── CONTAINER ──────────────────────────────────── */
.container {
  max-width: 1060px;
  margin: 0 auto;
  padding: 0 48px;
}

/* ─── KEYFRAMES ──────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ─── HERO (INDEX) ───────────────────────────────── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 120px 0 80px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(88,166,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(88,166,255,0.025) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  top: -160px; right: -160px;
  width: 680px; height: 680px;
  background: radial-gradient(circle, rgba(88,166,255,0.065) 0%, transparent 65%);
  pointer-events: none;
}

.hero .container { position: relative; z-index: 1; }

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 56px;
  align-items: center;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 20px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.1s;
}

.hero-eyebrow::before {
  content: '';
  width: 22px; height: 1px;
  background: var(--accent);
  flex-shrink: 0;
}

.hero-copy h1 {
  font-size: clamp(30px, 4.5vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1.2px;
  margin-bottom: 20px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.2s;
}

.hero-copy h1 .accent { color: var(--accent); }

.hero-copy .lede {
  font-size: 15px;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.85;
  margin-bottom: 36px;
  max-width: 500px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.3s;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.4s;
}

.hero-copy .micro {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.05em;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.5s;
}

/* hero card */
.hero-card-wrap {
  opacity: 0;
  animation: fadeUp 0.7s ease forwards 0.5s;
}

.hero-card-wrap .card {
  position: relative;
}

.hero-card-wrap .card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 9px;
  background: linear-gradient(135deg, rgba(88,166,255,0.25), transparent 60%);
  z-index: 0;
  pointer-events: none;
}

/* ─── PAGE HEAD (interior pages) ─────────────────── */
.page-head {
  padding: 140px 0 64px;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.page-head::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(88,166,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(88,166,255,0.02) 1px, transparent 1px);
  background-size: 44px 44px;
  pointer-events: none;
}

.page-head::after {
  content: '';
  position: absolute;
  top: -120px; right: -120px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(88,166,255,0.055) 0%, transparent 65%);
  pointer-events: none;
}

.page-head .container { position: relative; z-index: 1; }

.page-eyebrow {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.page-eyebrow::before {
  content: '';
  width: 18px; height: 1px;
  background: var(--border);
}

.page-head h1 {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1.1;
  margin-bottom: 16px;
}

.page-head h1 .accent { color: var(--accent); }

.page-head .lede {
  font-size: 15px;
  font-weight: 300;
  color: var(--muted);
  max-width: 560px;
  line-height: 1.85;
}

/* ─── SECTION WRAPPER ────────────────────────────── */
.section {
  padding: 72px 0;
}

.section.alt {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-label::before {
  content: '';
  width: 18px; height: 1px;
  background: var(--border);
}

.section-title {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.4px;
  margin-bottom: 12px;
}

.section-title .accent { color: var(--accent); }

.section-desc {
  color: var(--muted);
  font-weight: 300;
  font-size: 14px;
  line-height: 1.85;
  max-width: 540px;
  margin-bottom: 36px;
}

/* ─── BUTTONS ────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent);
  color: var(--bg);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 11px 22px;
  border-radius: 5px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.btn:hover {
  background: #79b8ff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(88,166,255,0.25);
}

.btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: transparent;
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 4px 16px rgba(88,166,255,0.1);
}

/* ─── CARDS ──────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
  position: relative;
}

.card.soft { background: var(--surface2); }

.card h2 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 12px;
}

.card h3 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 10px;
}

.card p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.card-title {
  font-size: 14px;
  font-weight: 600;
  font-family: 'IBM Plex Mono', monospace;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.card-links {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.card-links a {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.05em;
  transition: opacity 0.2s;
}

.card-links a:hover { opacity: 0.75; }

/* ─── PILL LIST (hero focus areas) ──────────────── */
.pill-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 0;
}

.pill-list li {
  font-size: 13px;
  color: var(--muted);
  padding: 7px 0 7px 0;
  border-bottom: 1px solid rgba(48,54,61,0.6);
  display: flex;
  align-items: center;
  gap: 8px;
}

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

.pill-list li::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
  opacity: 0.6;
}

/* ─── ANCHOR QUOTE / BAND ────────────────────────── */
.band {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 48px 0;
}

.anchor-quote {
  font-size: clamp(18px, 2.5vw, 24px);
  font-weight: 300;
  color: var(--text);
  line-height: 1.6;
  letter-spacing: -0.3px;
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
  font-style: italic;
  position: relative;
  padding: 0 24px;
}

.anchor-quote::before {
  content: '"';
  font-family: 'IBM Plex Mono', monospace;
  font-size: 48px;
  color: rgba(88,166,255,0.2);
  position: absolute;
  left: 0; top: -16px;
  line-height: 1;
}

/* ─── TWO-COL ────────────────────────────────────── */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}

.two-col h2 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 14px;
  letter-spacing: -0.3px;
}

.two-col p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.85;
  margin-bottom: 12px;
}

/* ─── GRID-3 ─────────────────────────────────────── */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.grid-3 .card h3 {
  font-size: 14px;
  font-family: 'IBM Plex Mono', monospace;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  margin-bottom: 10px;
}

/* ─── CTA SECTION ────────────────────────────────── */
.cta {
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
}

.cta h2 {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.3px;
  margin-bottom: 12px;
}

.cta p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.85;
  margin-bottom: 28px;
}

/* ─── PROSE (about / work) ───────────────────────── */
.prose {
  max-width: 720px;
}

.prose h2 {
  font-size: 19px;
  font-weight: 600;
  margin: 36px 0 12px;
  letter-spacing: -0.3px;
  padding-top: 36px;
  border-top: 1px solid var(--border);
}

.prose h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.prose p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.9;
  margin-bottom: 14px;
}

.prose p strong { color: var(--text); font-weight: 600; }

.callout {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: 0 6px 6px 0;
  padding: 16px 20px;
  margin: 24px 0;
}

.callout p {
  color: var(--text) !important;
  font-size: 14px !important;
  margin: 0 !important;
}

/* ─── WORK TIMELINE ──────────────────────────────── */
.work-timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.work-entry {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 32px;
  padding: 32px 0;
  border-bottom: 1px solid var(--border);
  position: relative;
}

.work-entry:last-child { border-bottom: none; }

.work-entry::before {
  content: '';
  position: absolute;
  left: 171px;
  top: 40px;
  width: 1px;
  height: calc(100% - 8px);
  background: var(--border);
}

.work-meta {
  padding-top: 3px;
}

.work-period {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.work-org {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--accent);
  font-weight: 600;
}

.work-content h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
  letter-spacing: -0.2px;
}

.work-content p {
  color: var(--muted);
  font-size: 13px;
  font-weight: 300;
  line-height: 1.8;
  margin-bottom: 10px;
}

.work-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.wtag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 3px;
  border: 1px solid;
}

.wtag.blue   { background: rgba(88,166,255,0.08);  border-color: rgba(88,166,255,0.25);  color: var(--accent); }
.wtag.green  { background: rgba(63,185,80,0.08);   border-color: rgba(63,185,80,0.25);   color: var(--green); }
.wtag.orange { background: rgba(255,166,87,0.08);  border-color: rgba(255,166,87,0.25);  color: var(--orange); }
.wtag.purple { background: rgba(210,168,255,0.08); border-color: rgba(210,168,255,0.25); color: var(--purple); }

/* ─── PROJECT CARDS ──────────────────────────────── */
.project-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s, transform 0.2s;
}

.project-card:hover {
  border-color: rgba(88,166,255,0.3);
  transform: translateY(-2px);
}

.project-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project-title {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.2px;
  line-height: 1.35;
}

.project-text {
  color: var(--muted);
  font-size: 13px;
  font-weight: 300;
  line-height: 1.8;
  flex: 1;
}

.project-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.project-bullets li {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
}

.project-bullets li::before {
  content: '▸';
  color: var(--accent);
  font-size: 9px;
}

.project-links {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* ─── CONTACT ────────────────────────────────────── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}

.contact-block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
}

.contact-block h3 {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 12px;
}

.contact-block a {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}

.contact-block a:hover { opacity: 0.75; }

.contact-block .sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 8px;
  font-weight: 300;
}

/* ─── TEXT LINK ──────────────────────────────────── */
.text-link {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
  transition: opacity 0.2s;
}

.text-link:hover { opacity: 0.75; }

.micro {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.04em;
  margin-top: 6px;
}

/* ─── FOOTER ─────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
  margin-top: 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}

.brand-footer {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.footer-small {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.footer-small.right { text-align: right; }

.footer-links {
  display: flex;
  gap: 20px;
  justify-content: center;
}

.footer-links a {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--accent); }

/* ─── ABOUT SKILLS GRID ──────────────────────────── */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 32px;
}

.skill-card {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 16px;
}

.skill-card .skill-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-weight: 600;
  margin-bottom: 8px;
}

.skill-card p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
}

/* ─── RESPONSIVE ─────────────────────────────────── */
@media (max-width: 860px) {
  .container { padding: 0 24px; }

  .nav-toggle { display: flex; }
  .site-nav {
    position: absolute;
    top: 58px; left: 0; right: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 16px 24px;
    gap: 4px;
    display: none;
  }
  .site-nav.open { display: flex; }

  .hero-grid { grid-template-columns: 1fr; }
  .hero-card-wrap { display: none; }
  .two-col { grid-template-columns: 1fr; gap: 24px; }
  .grid-3 { grid-template-columns: 1fr; }
  .project-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .skills-grid { grid-template-columns: 1fr 1fr; }
  .work-entry { grid-template-columns: 1fr; gap: 8px; }
  .work-entry::before { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: 16px; }
  .footer-small.right { text-align: left; }
}

@media (max-width: 520px) {
  .hero-copy h1 { font-size: 28px; }
  .skills-grid { grid-template-columns: 1fr; }
}
