:root {
  --bg: #0c0d10;
  --surface: #14161c;
  --surface-light: #1b1e26;
  --primary: #6f7cff;
  --primary-light: #8f9bff;
  --text: #f2f2f4;
  --muted: #b3b6c2;
  --accent: #9ad5c3;
  --border: rgba(255, 255, 255, 0.08);
  --glow: rgba(111, 124, 255, 0.2);
}

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

body {
  font-family: "Inter", sans-serif;
  background: radial-gradient(circle at top, #1a1d24 0%, #0c0d10 45%, #0c0d10 100%);
  color: var(--text);
  line-height: 1.6;
  transition: background 0.3s ease, color 0.3s ease;
}

body.light {
  --bg: #f3f4f7;
  --surface: #ffffff;
  --surface-light: #f1f2f6;
  --primary: #4657ff;
  --primary-light: #5c6bff;
  --text: #0f111a;
  --muted: #5f677a;
  --accent: #4aa889;
  --border: rgba(15, 17, 26, 0.08);
  --glow: rgba(70, 87, 255, 0.2);
  background: radial-gradient(circle at top, #ffffff 0%, #f3f4f7 55%, #f3f4f7 100%);
}

a {
  color: inherit;
  text-decoration: none;
}

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

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

.logo {
  font-weight: 700;
  font-size: 1.2rem;
  background: linear-gradient(120deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  color: transparent;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface-light);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.2s ease, border 0.2s ease;
}

.theme-toggle:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.2);
}

.theme-dot {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 0 12px var(--glow);
}

.nav-links a {
  color: var(--muted);
  font-weight: 500;
  transition: color 0.2s ease;
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 0.3rem;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text);
}

main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
  align-items: center;
  margin: 2rem 0 4rem;
}

.hero-content h1 {
  font-size: clamp(1.35rem, 2.1vw, 2.15rem);
  white-space: nowrap;
  letter-spacing: -0.04em;
  margin: 0.5rem 0 1rem;
}

.subtitle {
  font-size: 1.1rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.75rem;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn.primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 12px 30px var(--glow);
}

.btn.ghost {
  border-color: var(--border);
  color: var(--text);
}

.btn:hover {
  transform: translateY(-2px);
}

.hero-meta {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  color: var(--muted);
}

.hero-stats {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.hero-stats div {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 1rem 1.25rem;
}

.hero-stats strong {
  font-size: 1.5rem;
  display: block;
  color: var(--primary-light);
}

.hero-stats span {
  color: var(--muted);
  font-size: 0.9rem;
}

.avatar {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  margin-bottom: 1.5rem;
}

.quick-info {
  list-style: none;
  margin-top: 1rem;
  display: grid;
  gap: 0.5rem;
  color: var(--muted);
}

.section {
  margin-top: 4rem;
}

.section-header h2 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.section-header p {
  color: var(--muted);
}

.section-body {
  margin-top: 1.5rem;
}

.two-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.highlight-box {
  background: var(--surface-light);
  padding: 1.5rem;
  border-radius: 18px;
  border: 1px solid var(--border);
}

.timeline {
  margin-top: 2rem;
  display: grid;
  gap: 1.5rem;
}

.timeline-item {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 1.5rem;
  background: var(--surface);
  padding: 1.5rem;
  border-radius: 18px;
  border: 1px solid var(--border);
  transition: transform 0.2s ease, border 0.2s ease;
}

.timeline-item:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.16);
}

.timeline-date {
  color: var(--primary-light);
  font-weight: 600;
}

.cards {
  margin-top: 2rem;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.card {
  background: var(--surface);
  padding: 1.5rem;
  border-radius: 18px;
  border: 1px solid var(--border);
  transition: transform 0.2s ease, border 0.2s ease;
  display: grid;
  gap: 0.75rem;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.16);
}

.card span {
  color: var(--muted);
}

.project .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.project .tags span {
  background: transparent;
  border: 1px solid rgba(145, 158, 255, 0.45);
  color: var(--primary-light);
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  line-height: 1;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.skill-tags span {
  background: transparent;
  border: 1px solid rgba(145, 158, 255, 0.45);
  color: var(--primary-light);
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  line-height: 1;
}

.skill-grid {
  margin-top: 2rem;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.skill {
  background: var(--surface-light);
  padding: 1.5rem;
  border-radius: 18px;
  border: 1px solid var(--border);
}

.tools-grid {
  margin-top: 2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.tool-card {
  background: var(--surface);
  padding: 1.5rem;
  border-radius: 18px;
  border: 1px solid var(--border);
  display: grid;
  gap: 0.75rem;
}

.game-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.game-output {
  color: var(--muted);
  font-size: 0.95rem;
}

.tool-card input[type="number"] {
  width: 140px;
  padding: 0.6rem 0.8rem;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface-light);
  color: var(--text);
}

.contact-box {
  margin-top: 2rem;
  background: var(--surface);
  border-radius: 20px;
  padding: 2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
  border: 1px solid var(--border);
}

.contact-lead {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

.contact-box ul {
  list-style: none;
  display: grid;
  gap: 0.6rem;
  color: var(--muted);
}

.contact-form {
  display: grid;
  gap: 1rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #0c0d10;
  color: var(--text);
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    transition: none;
    opacity: 1;
    transform: none;
  }
}

.site-footer {
  text-align: center;
  padding: 2rem 1.5rem;
  color: var(--muted);
  border-top: 1px solid var(--border);
}


@media (max-width: 860px) {
  .timeline-item {
    grid-template-columns: 1fr;
  }

  .nav-links {
    position: absolute;
    top: 70px;
    right: 24px;
    flex-direction: column;
    background: var(--surface);
    padding: 1rem 1.5rem;
    border-radius: 14px;
    border: 1px solid var(--border);
    display: none;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

  .theme-toggle {
    order: 1;
  }
}
