/* Reset & Base */
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji";
  color: #eaeaea;
  background: #0b0b0b;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:root {
  --bg: #0b0b0b;
  --fg: #ffffff;
  --muted: #9b9b9b;
  --card: rgba(255,255,255,0.04);
  --card-stroke: rgba(255,255,255,0.08);
  --glass: rgba(255,255,255,0.06);
  --glass-stroke: rgba(255,255,255,0.1);
  --shadow: 0 10px 30px rgba(0,0,0,0.5);
}

/* Canvas background full-bleed */
#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  background: var(--bg);
}

/* Top navigation */
.topnav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  background: linear-gradient(to bottom, rgba(0,0,0,0.7), rgba(0,0,0,0));
  border-bottom: 1px solid rgba(255,255,255,0.06);
  backdrop-filter: blur(10px);
}
.topnav .brand {
  font-weight: 600;
  letter-spacing: 0.3px;
}
.nav { display: flex; gap: 20px; }
.nav-link {
  color: #d8d8d8;
  text-decoration: none;
  font-size: 0.95rem;
  padding: 6px 10px;
  border-radius: 8px;
  transition: color .2s ease, background .2s ease;
}
.nav-link:hover { color: var(--fg); background: rgba(255,255,255,0.06); }

/* Container */
.container {
  width: min(1100px, 92vw);
  margin: 0 auto;
  padding: 64px 0 96px;
}

/* Hero */
.hero { padding: 56px 0 24px; }
.title {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.1;
  margin: 0 0 12px;
  letter-spacing: -0.02em;
}
.subtitle {
  color: var(--muted);
  max-width: 760px;
  margin: 0 0 28px;
}
.cta { display: flex; gap: 12px; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid var(--glass-stroke);
  background: var(--glass);
  color: var(--fg);
  text-decoration: none;
  transition: transform .15s ease, background .2s ease, border-color .2s ease;
  box-shadow: var(--shadow);
}
.btn:hover { transform: translateY(-1px); background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.18); }
.btn.primary { background: #ffffff; color: #0b0b0b; border-color: transparent; }
.btn.primary:hover { background: #f0f0f0; }
.btn.ghost { background: transparent; border-color: rgba(255,255,255,0.18); }
.btn.tiny { padding: 8px 10px; border-radius: 10px; font-size: 0.9rem; }

/* Sections */
.section { padding: 48px 0; display: none; }
.section.active { display: block; }
.section-title { font-size: 1.6rem; margin: 0 0 16px; letter-spacing: -0.01em; }
.section-text { color: var(--muted); max-width: 820px; }

/* Active nav link */
.nav-link.active { color: var(--fg); background: rgba(255,255,255,0.08); }

/* Language toggle - minimal plain text style */
.lang-toggle {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
  opacity: 0.7;
}
.lang-btn {
  background: none;
  border: none;
  color: var(--muted);
  font-size: 0.85rem;
  padding: 4px 8px;
  cursor: pointer;
  transition: color 0.2s ease;
  text-decoration: underline;
  text-decoration-color: transparent;
}
.lang-btn:hover {
  color: var(--fg);
  text-decoration-color: rgba(255,255,255,0.3);
}
.lang-btn.active {
  color: var(--fg);
  text-decoration-color: rgba(255,255,255,0.6);
}

/* Highlight text - subtle italic emphasis */
.highlight {
  color: var(--fg);
  font-style: italic;
  font-weight: 500;
}

/* Info grid */
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 16px;
  margin-top: 20px;
}
.info-item {
  padding: 16px;
  border-radius: 14px;
  background: var(--card);
  border: 1px solid var(--card-stroke);
}
.info-item h3 { margin: 0 0 8px; font-size: 1rem; }
.info-item p { margin: 0; color: var(--muted); }

/* Projects */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 16px;
}
.card {
  padding: 18px;
  border-radius: 16px;
  background: var(--card);
  border: 1px solid var(--card-stroke);
  box-shadow: var(--shadow);
}
.card-title { margin: 0 0 8px; font-size: 1.1rem; }
.card-text { margin: 0 0 14px; color: var(--muted); }
.card-actions { display: flex; gap: 10px; }

/* Links */
.links { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
.link { color: #fff; opacity: .88; text-decoration: none; border-bottom: 1px dashed rgba(255,255,255,0.2); padding-bottom: 2px; }
.link:hover { opacity: 1; border-bottom-color: rgba(255,255,255,0.4); }

/* Footer */
.footer {
  width: 100%;
  border-top: 1px solid rgba(255,255,255,0.06);
  padding: 28px 24px 56px;
  display: flex;
  justify-content: center;
  color: #9a9a9a;
  background: linear-gradient(to top, rgba(0,0,0,0.7), rgba(0,0,0,0));
}

/* Responsive */
@media (max-width: 900px) {
  .projects-grid, .info-grid { grid-template-columns: 1fr; }
  .nav { gap: 12px; }
}