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

:root {
  --bg: #0d0d0d;
  --bg-alt: #141414;
  --surface: #1a1a1a;
  --border: #2a2a2a;
  --text: #e8e8e8;
  --text-secondary: #c0c0c0;  /* body / descriptions */
  --text-muted: #888;          /* metadata: dates, locations, company */
  --accent: #7aff8f;   /* celery green */
  --accent-dim: #3a7d44;
  --font: 'Inter', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', 'Fira Code', monospace;
  --radius: 8px;
  --max-w: 1200px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
}

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

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

.nav {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
}
.logo:hover { text-decoration: none; opacity: 0.85; }

.logo-img {
  height: 72px;
  width: auto;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
}
.nav-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); text-decoration: none; }

/* ── Hero ── */
.hero {
  min-height: calc(100vh - 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 0;
}

.hero-content {
  max-width: 720px;
  text-align: center;
}


.hero-eyebrow {
  font-family: var(--mono);
  font-size: 0.85rem;
  color: var(--accent);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 3.75rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -2px;
  margin-bottom: 1.25rem;
  white-space: nowrap;
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto 2rem;
}

.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }

/* ── Buttons ── */
.btn {
  display: inline-block;
  padding: 0.65rem 1.5rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  transition: all 0.2s;
  cursor: pointer;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: #000;
}
.btn-primary:hover { background: #a3ffa3; text-decoration: none; }

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

/* ── Sections ── */
.section { padding: 6rem 0; }
.section-alt { background: var(--bg-alt); }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 2rem; }

.section-title {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 2rem;
}

.section-body {
  color: var(--text-secondary);
  max-width: 640px;
  font-size: 1.05rem;
}

/* ── Skills Grid ── */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 0.5rem;
}

.skill-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  transition: border-color 0.2s;
}
.skill-card:hover { border-color: var(--accent-dim); }

.skill-card h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 0.4rem;
}

.skill-card p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ── Tech Stack Icons ── */
.tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  align-items: center;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.tech-stack a {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.2s, transform 0.2s;
}

.tech-stack a:hover {
  transform: translateY(-2px);
  opacity: 1;
}

.tech-stack img {
  width: 28px;
  height: 28px;
}

/* These brand colors are too dark for a dark background — force white */
.tech-stack img[alt="Helm"],
.tech-stack img[alt="Sentry"],
.tech-stack img[alt="Apache Kafka"] {
  filter: brightness(0) invert(1);
  opacity: 0.75;
}
.tech-stack a:hover img[alt="Helm"],
.tech-stack a:hover img[alt="Sentry"],
.tech-stack a:hover img[alt="Apache Kafka"] {
  opacity: 1;
}


.tech-disclaimer {
  margin-top: 1rem;
  font-size: 0.72rem;
  color: var(--text-muted);
  opacity: 0.6;
}

/* ── Projects ── */
.project-list { display: flex; flex-direction: column; gap: 1rem; }

.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.project-card h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}
.project-card p { color: var(--text-muted); font-size: 0.9rem; }

/* ── Hero role line ── */
.hero-role {
  font-size: 1.1rem;
  color: var(--accent);
  font-family: var(--mono);
  margin-bottom: 0.75rem;
}

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

.timeline-item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 1.5rem;
  padding: 2rem 0;
  border-top: 1px solid var(--border);
}
.timeline-item:last-child { border-bottom: 1px solid var(--border); }

.timeline-meta {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding-top: 0.15rem;
}

.timeline-date {
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--text-muted);
}

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

.timeline-role {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

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

.timeline-via {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.timeline-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.timeline-bullets li {
  font-size: 0.9rem;
  color: var(--text-secondary);
  padding-left: 1rem;
  position: relative;
  line-height: 1.65;
}

.timeline-bullets li::before {
  content: "–";
  position: absolute;
  left: 0;
  color: var(--accent-dim);
}

/* ── Education ── */
.edu-list { display: flex; flex-direction: column; gap: 0; }

.edu-item {
  display: grid;
  grid-template-columns: 180px 1fr 170px;
  gap: 1.5rem;
  align-items: center;
  padding: 1.5rem 0;
  border-top: 1px solid var(--border);
}
.edu-item:last-child { border-bottom: 1px solid var(--border); }

.edu-meta { display: flex; flex-direction: column; gap: 0.3rem; padding-top: 0.1rem; align-self: center; }

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

.edu-school { font-size: 0.85rem; color: var(--text-muted); margin-top: 0.2rem; }

.edu-logo { display: block; object-fit: contain; justify-self: end; }
.edu-logo--wide  { width: 160px; height: auto; }
.edu-logo--square {
  width: 64px;
  height: 64px;
  background: #fff;
  border-radius: 50%;
  padding: 4px;
}

/* ── Contact links ── */
.contact-links { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 1.5rem; }

/* ── Responsive ── */
@media (max-width: 768px) {
  .logo-img { height: 48px; }
  .hero-title { white-space: normal; }
}

@media (max-width: 600px) {
  .timeline-item { grid-template-columns: 1fr; gap: 0.5rem; }
  .edu-item { grid-template-columns: 1fr auto; gap: 0.75rem; }
  .edu-item .edu-meta { display: none; }
  .timeline-meta { flex-direction: row; gap: 1rem; }
  .edu-logo--wide { width: 90px; }
  .edu-logo--square { width: 36px; height: 36px; }
}

/* ── Chatbot ── */
.chat-fab {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(122,255,143,0.35);
  transition: transform 0.2s, box-shadow 0.2s;
  z-index: 999;
}
.chat-fab:hover { transform: scale(1.08); box-shadow: 0 6px 28px rgba(122,255,143,0.5); }
.chat-fab svg { width: 24px; height: 24px; }

.chat-window {
  position: fixed;
  bottom: 5.5rem;
  right: 2rem;
  width: 320px;
  max-height: 420px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 40px rgba(0,0,0,0.5);
  z-index: 998;
  overflow: hidden;
  transform: scale(0.92) translateY(12px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.chat-window.open {
  transform: scale(1) translateY(0);
  opacity: 1;
  pointer-events: all;
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}
.chat-header-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 6px var(--accent);
  flex-shrink: 0;
}
.chat-header-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  flex: 1;
}
.chat-header-sub {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-family: var(--mono);
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.chat-msg {
  max-width: 85%;
  padding: 0.55rem 0.85rem;
  border-radius: 10px;
  font-size: 0.82rem;
  line-height: 1.5;
}
.chat-msg.bot {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  align-self: flex-start;
  border-bottom-left-radius: 3px;
}
.chat-msg.user {
  background: var(--accent);
  color: #0d0d0d;
  align-self: flex-end;
  border-bottom-right-radius: 3px;
  font-weight: 500;
}
.chat-msg.typing { opacity: 0.6; font-style: italic; }

.chat-suggestions {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  padding: 0.5rem 0.75rem 0.25rem;
  border-top: 1px solid var(--border);
}
.chat-suggestions.hidden { display: none; }

.chat-suggestion {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.45rem 0.75rem;
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-family: var(--font);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.chat-suggestion::before {
  content: "▷";
  font-size: 0.7rem;
  color: var(--accent);
  flex-shrink: 0;
}
.chat-suggestion:hover {
  border-color: var(--accent);
  color: var(--text);
}

.chat-input-row {
  display: flex;
  gap: 0.5rem;
  padding: 0.75rem;
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
}
.chat-input {
  flex: 1;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  color: var(--text);
  font-family: var(--font);
  font-size: 0.82rem;
  outline: none;
  transition: border-color 0.15s;
}
.chat-input:focus { border-color: var(--accent); }
.chat-input::placeholder { color: var(--text-muted); }
.chat-send {
  background: var(--accent);
  border: none;
  border-radius: 6px;
  padding: 0 0.75rem;
  cursor: pointer;
  color: #0d0d0d;
  font-size: 1rem;
  transition: opacity 0.15s;
}
.chat-send:hover { opacity: 0.85; }

/* ── Footer ── */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}
