:root {
  --bg:        #0f0f0f;
  --border:    #1c1c1c;
  --text:      #e2e2e2;
  --muted:     #4f4f4f;
  --muted-mid: #888;
  --body-text: #888;
  --nav-h:     52px;
  --max-w:     600px;
}

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

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', sans-serif;
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* ─── PAGES ──────────────────────────────────────────── */

.page {
  display: none;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 72px 24px 120px;
  min-height: 100vh;
  animation: fadeUp 0.22s ease;
}

.page.active { display: block; }

#home.page.active {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding-top: 48px;
  padding-bottom: 96px;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ─── HOME ───────────────────────────────────────────── */

.home-name {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 20px;
}

.home-tagline {
  color: var(--text);
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.7;
  margin-bottom: 24px;
}

.home-tagline a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.15s;
}

.home-tagline a:hover { opacity: 0.6; }

.home-bio {
  color: var(--body-text);
  font-size: 0.9375rem;
  line-height: 1.8;
  margin-bottom: 36px;
}

.home-bio a {
  color: var(--muted-mid);
  text-decoration: none;
  transition: color 0.15s;
}

.home-bio a:hover { color: var(--text); }

.home-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.home-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.8125rem;
  transition: color 0.15s;
}

.home-links a:hover { color: var(--text); }

/* ─── SECTION LABEL ──────────────────────────────────── */

.section-label {
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--muted);
  margin-bottom: 36px;
}

/* ─── WORK ───────────────────────────────────────────── */

.work-item {
  padding-bottom: 36px;
  margin-bottom: 36px;
  border-bottom: 1px solid var(--border);
}

.work-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.work-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 2px;
}

.work-company {
  font-weight: 600;
  font-size: 0.9375rem;
}

.work-company a {
  color: inherit;
  text-decoration: none;
  transition: opacity 0.15s;
}

.work-company a:hover { opacity: 0.7; }

.work-date {
  color: var(--muted);
  font-size: 0.8125rem;
  white-space: nowrap;
  flex-shrink: 0;
}

.work-role {
  color: #c0c0c0;
  font-weight: 500;
  font-size: 0.8125rem;
  margin-bottom: 14px;
  letter-spacing: 0.01em;
}

.work-description {
  color: var(--body-text);
  font-size: 0.875rem;
  line-height: 1.8;
}

/* ─── WORK SUB-ROLES (e.g. Trivago progression) ─────── */

.work-subroles {
  margin-top: 16px;
}

.work-subrole {
  padding: 16px 0;
  border-top: 1px solid var(--border);
}

.work-subrole:first-child {
  padding-top: 0;
  border-top: none;
}

.work-subrole-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 8px;
}

.work-subrole-header:last-child { margin-bottom: 0; }

.work-subrole-title {
  color: #c0c0c0;
  font-weight: 500;
  font-size: 0.875rem;
  letter-spacing: 0.01em;
}

.work-subrole-date {
  color: var(--muted);
  font-size: 0.8125rem;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ─── PROJECTS ───────────────────────────────────────── */

.project-item {
  padding-bottom: 28px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--border);
}

.project-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.project-name {
  margin-bottom: 8px;
}

.project-name a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9375rem;
  transition: color 0.15s;
}

.project-name a:hover { color: #fff; }

.project-description {
  color: var(--body-text);
  font-size: 0.875rem;
  line-height: 1.8;
}

/* ─── BOTTOM NAV (pill / glass) ──────────────────────── */

.bottom-nav {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  background: rgba(22, 22, 22, 0.72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 999px;
  z-index: 100;
  white-space: nowrap;
}

.nav-link {
  color: var(--muted-mid);
  text-decoration: none;
  font-size: 0.8125rem;
  letter-spacing: 0.01em;
  padding: 7px 18px;
  border-radius: 999px;
  transition: color 0.15s, background 0.15s;
}

.nav-link:hover { color: var(--text); }

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

/* ─── RESPONSIVE ─────────────────────────────────────── */

@media (max-width: 480px) {
  .work-header {
    flex-direction: column;
    gap: 2px;
  }
  .work-date { margin-bottom: 2px; }
}
