:root {
  --bg: #070b12;
  --surface: #0d1522;
  --surface-strong: #111f31;
  --ink: #f5f8ff;
  --muted: #a5b6cf;
  --line: #21324a;
  --accent: #2f8bff;
  --accent-alt: #ff7a2f;
  --max-width: 1040px;
  --shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "Sora", sans-serif;
  line-height: 1.6;
  background:
    radial-gradient(circle at 88% 10%, rgba(47, 139, 255, 0.23), transparent 28%),
    radial-gradient(circle at 10% 90%, rgba(255, 122, 47, 0.2), transparent 26%),
    linear-gradient(140deg, #060a11 0%, #070d15 55%, #0a121c 100%);
  overflow-x: hidden;
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at center, black 30%, transparent 85%);
}

.bg-glow {
  position: fixed;
  width: 34rem;
  height: 34rem;
  right: -10rem;
  top: -10rem;
  z-index: -1;
  pointer-events: none;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(47, 139, 255, 0.28), transparent 65%);
  filter: blur(30px);
}

.site-header {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.15rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.2rem;
}

.brand {
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 0.35rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(17, 31, 49, 0.55);
}

.nav-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  padding: 0.35rem 0.5rem;
  border-radius: 0.45rem;
  transition: color 180ms ease, background-color 180ms ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--ink);
  background: rgba(47, 139, 255, 0.18);
}

main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1rem;
}

.hero {
  padding: 3.8rem 0 2.6rem;
}

.eyebrow {
  margin: 0 0 0.8rem;
  font-family: "IBM Plex Mono", monospace;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.82rem;
}

h1 {
  margin: 0;
  max-width: 17ch;
  line-height: 1.06;
  font-size: clamp(2rem, 5.7vw, 4.5rem);
}

h1 span {
  display: block;
  color: #d8e8ff;
  font-weight: 600;
}

.hero-copy {
  margin: 1.35rem 0 1.75rem;
  max-width: 62ch;
  color: var(--muted);
}

.hero-visual {
  margin: 0 0 1.2rem;
  max-width: 680px;
  border-radius: 0.78rem;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
}

.hero-visual img {
  display: block;
  width: 100%;
  height: auto;
}

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

.btn {
  text-decoration: none;
  padding: 0.72rem 1.12rem;
  border-radius: 0.62rem;
  font-weight: 600;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

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

.btn-primary {
  background: linear-gradient(145deg, #2476dd, #2f8bff);
  color: #ffffff;
  box-shadow: 0 12px 26px rgba(47, 139, 255, 0.25);
}

.btn-ghost {
  color: var(--ink);
  border: 1px solid var(--line);
  background: rgba(17, 31, 49, 0.55);
}

.panel {
  margin: 1.2rem 0;
  padding: 1.4rem;
  border-radius: 1rem;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(17, 31, 49, 0.92), rgba(13, 21, 34, 0.88));
  box-shadow: var(--shadow);
}

h2 {
  margin-top: 0;
  margin-bottom: 0.7rem;
  font-size: clamp(1.28rem, 2.8vw, 2rem);
}

.section-head p,
.panel p {
  margin-top: 0;
  color: var(--muted);
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.85rem;
}

.project-card {
  border: 1px solid var(--line);
  border-radius: 0.78rem;
  background: rgba(5, 10, 18, 0.55);
  padding: 1rem;
}

.project-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.project-card p {
  margin-bottom: 0.7rem;
}

.project-thumb {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0.55rem;
  border: 1px solid #2d4768;
  margin-bottom: 0.7rem;
}

.project-card ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0;
  margin: 0 0 0.8rem;
}

.project-card li {
  font-size: 0.76rem;
  font-family: "IBM Plex Mono", monospace;
  color: #d8e8ff;
  border: 1px solid #2d4768;
  border-radius: 999px;
  padding: 0.2rem 0.5rem;
}

.project-link {
  color: #8ec1ff;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.15rem;
}

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

.skill-tags span {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
  border: 1px solid var(--line);
  border-radius: 0.45rem;
  padding: 0.34rem 0.52rem;
  color: #cee0fb;
  background: rgba(6, 12, 20, 0.64);
}

.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.contact-links a {
  color: #9dc8ff;
}

footer {
  max-width: var(--max-width);
  margin: 2.2rem auto 1.2rem;
  padding: 0 1rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.82rem;
  color: #90a7c8;
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 460ms ease, transform 460ms ease;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent-alt);
  outline-offset: 2px;
}

@media (max-width: 780px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero {
    padding-top: 2.6rem;
  }

  .panel {
    padding: 1rem;
  }
}
