:root {
  --bg: #07090f;
  --surface: rgba(15, 21, 32, 0.78);
  --surface-strong: #101722;
  --text: #f6f8fb;
  --muted: #aab5c4;
  --line: rgba(112, 183, 255, 0.2);
  --cyan: #56d6ff;
  --gold: #f7bd4b;
  --accent: #ff5a45;
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 18% 8%, rgba(86, 214, 255, 0.13), transparent 28rem),
    radial-gradient(circle at 86% 14%, rgba(255, 90, 69, 0.1), transparent 26rem),
    linear-gradient(145deg, #07090f 0%, #0b1018 48%, #07090f 100%);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(86, 214, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(86, 214, 255, 0.035) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(to bottom, #000, transparent 74%);
}

/* animated cyber-grid: very faint, slow panning for a subtle network feel */
body::before {
  z-index: -2;
  background-position: 0 0;
  animation: gridPan 80s linear infinite;
}

@keyframes gridPan {
  0% { background-position: 0 0; }
  50% { background-position: -120px -72px; }
  100% { background-position: 0 0; }
}

/* keep the existing fixed tiled background and avoid extra overlay here */

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 18px 0;
  transition: padding 180ms ease;
}

.site-header.is-scrolled {
  padding: 10px 0;
}

.site-header.is-scrolled::before {
  content: "";
  position: absolute;
  inset: 6px -14px;
  z-index: -1;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(7, 9, 15, 0.82);
  backdrop-filter: blur(18px);
}

.brand,
nav {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
  color: var(--text);
  font-size: 0.95rem;
  letter-spacing: 0.5px;
}

.brand-mark {
  width: 12px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 18px rgba(86, 214, 255, 0.9);
}

.brand-text {
  display: none;
}

@media (min-width: 768px) {
  .brand-text {
    display: inline;
  }
}

.brand-text {
  display: none;
}

@media (min-width: 768px) {
  .brand-text {
    display: inline;
  }
}

nav {
  gap: 10px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.25px;
}

.nav-link {
  position: relative;
  padding: 10px 15px;
  border-radius: 999px;
  transition: color 180ms ease, background 180ms ease, transform 180ms ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 4px;
  width: 0;
  height: 2px;
  background: linear-gradient(135deg, var(--cyan), var(--gold));
  border-radius: 999px;
  transform: translateX(-50%);
  transition: width 180ms ease;
}

.nav-link:hover {
  color: var(--text);
  background: rgba(86, 214, 255, 0.08);
  transform: translateY(-1px);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 65%;
}

.nav-link.active {
  color: var(--cyan);
  background: rgba(86, 214, 255, 0.12);
}

.nav-link.active::after {
  background: var(--cyan);
}

.section-shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding-top: 72px;
  padding-bottom: 72px;
}

.about-section {
  padding-top: 84px;
  padding-bottom: 84px;
}

.about-section h2 {
  margin-top: 12px;
  margin-bottom: 28px;
  color: var(--cyan);
  font-size: 2.4rem;
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
  gap: 40px;
  align-items: center;
}

.hero {
  padding-top: 76px;
  padding-bottom: 84px;
}

.projects,
.achievement-grid,
.skills-grid,
.education-timeline {
  gap: 28px;
}

.project-card,
.achievement-grid > *,
.skills-grid article,
.education-card {
  padding: 28px;
}

.section-heading {
  padding-top: 84px;
  padding-bottom: 24px;
}

.about-text p {
  color: var(--muted);
  line-height: 1.75;
  margin-top: 20px;
}

.hero-profile {
  display: flex;
  justify-content: center;
  align-items: center;
}

.profile-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(16, 23, 34, 0.86), rgba(9, 13, 20, 0.7));
  box-shadow: var(--shadow);
  padding: 40px 32px;
  text-align: center;
  max-width: 340px;
}

.profile-card h2 {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 1.85rem;
  line-height: 1.1;
}

.profile-title {
  margin: 0 0 28px;
  color: var(--cyan);
  font-size: 0.95rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.profile-highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

.profile-highlights div {
  font-size: 0.85rem;
}

.profile-highlights strong {
  display: block;
  color: var(--gold);
  margin-bottom: 4px;
  font-weight: 700;
}

.profile-highlights span {
  color: var(--muted);
  font-size: 0.8rem;
}

.about-photo {
  display: flex;
  justify-content: center;
}

.about-photo img {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 9999px;
  border: 3px solid rgba(86, 214, 255, 0.18);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.28);
}

/* interactive mouse glow: a subtle, blurred radial gradient that follows the cursor */
.mouse-glow {
  position: fixed;
  left: 0;
  top: 0;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  pointer-events: none;
  mix-blend-mode: screen;
  background: radial-gradient(circle at 50% 50%, rgba(86,214,255,0.14) 0%, rgba(86,214,255,0.04) 30%, rgba(10,18,30,0.0) 60%);
  filter: blur(72px);
  opacity: 0.9;
  transform: translate3d(-9999px, -9999px, 0);
  will-change: transform, opacity;
  z-index: -1;
}

/* Removed custom overlay styles to restore original UI look */

/* Preserve original hero and section styling without card panels */

.eyebrow,
.card-kicker {
  margin: 0 0 14px;
  color: var(--cyan);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: var(--muted);
  text-transform: none;
  font-weight: 600;
  font-size: 1rem;
}

.hero .eyebrow {
  color: var(--muted);
  text-transform: none;
  font-weight: 600;
  font-size: 1rem;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 730px;
  margin-bottom: 22px;
  font-size: 4.15rem;
  line-height: 1.02;
}

h2 {
  margin-bottom: 0;
  font-size: 2.85rem;
  line-height: 1.08;
}

h3 {
  margin-bottom: 12px;
  font-size: 1.28rem;
}

.hero-text {
  max-width: 690px;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.8;
}

.hero-actions,
.project-actions,
.contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button,
.project-actions a,
.contact-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--text);
  font-weight: 800;
  background: rgba(255, 255, 255, 0.04);
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.button:hover,
.project-actions a:hover,
.contact-links a:hover {
  transform: translateY(-2px);
  border-color: rgba(86, 214, 255, 0.7);
  background: rgba(86, 214, 255, 0.1);
}

.button.primary {
  border-color: transparent;
  color: #170704;
  background: linear-gradient(135deg, var(--gold), var(--accent));
}

.signal-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  max-width: 640px;
  margin-top: 34px;
}

.signal-grid div,
.mission-grid article,
.project-card,
.education-card,
.achievement-grid > *,
.skills-grid article,
.contact {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(16, 23, 34, 0.86), rgba(9, 13, 20, 0.7));
  box-shadow: var(--shadow);
}

.signal-grid div {
  padding: 18px;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.signal-grid strong {
  display: block;
  color: var(--gold);
  font-size: 1.55rem;
}

.signal-grid span,
.profile-readout span {
  color: var(--muted);
  font-size: 0.82rem;
}

.section-heading {
  padding: 70px 0 22px;
}

.mission-grid,
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.mission-grid article,
.skills-grid article {
  padding: 24px;
}

.mission-grid p,
.project-card p,
.education-card p,
.achievement-grid p,
.skills-grid p,
.contact p {
  color: var(--muted);
  line-height: 1.7;
}

.mission-grid strong {
  color: var(--gold);
}

.education-timeline {
  position: relative;
  display: grid;
  gap: 44px;
  padding: 18px 0 36px;
}

.education-timeline::before {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 36px;
  left: 50%;
  width: 2px;
  border-radius: 999px;
  background: linear-gradient(to bottom, var(--cyan), rgba(247, 189, 75, 0.85));
  transform: translateX(-50%);
}

.education-card {
  position: relative;
  width: calc(50% - 44px);
  padding: 24px;
}

.education-card:nth-child(odd) {
  justify-self: start;
}

.education-card:nth-child(even) {
  justify-self: end;
}

.education-card h3,
.achievement-grid h3 {
  margin-bottom: 8px;
}

.education-card p {
  margin-bottom: 12px;
}

.education-card strong,
.education-card span:not(.timeline-dot) {
  display: block;
}

.education-card strong {
  margin-bottom: 10px;
  color: var(--cyan);
}

.education-card span:not(.timeline-dot) {
  color: var(--muted);
}

.timeline-dot {
  position: absolute;
  top: 28px;
  width: 18px;
  aspect-ratio: 1;
  border: 4px solid var(--bg);
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 28px rgba(86, 214, 255, 0.65);
}

.education-card:nth-child(odd) .timeline-dot {
  right: -53px;
}

.education-card:nth-child(even) .timeline-dot {
  left: -53px;
}

.projects {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 16px;
}

.project-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 430px;
  padding: 28px;
}

.project-card.featured {
  border-color: rgba(86, 214, 255, 0.24);
}

.project-card ul {
  margin: 20px 0 0;
  padding-left: 20px;
  color: var(--text);
  line-height: 1.75;
}

.project-actions {
  margin-top: 28px;
}

.achievement-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.achievement-grid > * {
  display: block;
  min-height: 210px;
  padding: 24px;
}

.achievement-icon {
  display: grid;
  place-items: center;
  width: 42px;
  aspect-ratio: 1;
  margin-bottom: 26px;
  border: 1px solid rgba(86, 214, 255, 0.22);
  border-radius: 8px;
  color: var(--gold);
  background: rgba(86, 214, 255, 0.1);
}

.skills-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.contact {
  display: grid;
  justify-items: center;
  gap: 24px;
  margin-top: 86px;
  margin-bottom: 72px;
  border: 0;
  padding: 92px 20px;
  text-align: center;
  background: transparent;
  box-shadow: none;
}

.contact h2 {
  margin-bottom: 16px;
  color: transparent;
  background: linear-gradient(135deg, #a985ff, var(--cyan));
  background-clip: text;
  -webkit-background-clip: text;
}

.contact p {
  max-width: 620px;
  margin-inline: auto;
}

.contact-links {
  justify-content: center;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  border-top: 1px solid var(--line);
  padding: 24px 0 36px;
  color: var(--muted);
  font-size: 0.92rem;
}

.mission-grid article,
.project-card,
.education-card,
.achievement-grid > *,
.skills-grid article,
.contact {
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.mission-grid article:hover,
.project-card:hover,
.education-card:hover,
.achievement-grid > *:hover,
.skills-grid article:hover {
  transform: translateY(-3px);
  border-color: rgba(86, 214, 255, 0.44);
}

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

  nav {
    width: 100%;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    padding: 6px 0;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  nav::-webkit-scrollbar {
    display: none;
  }

  nav a {
    flex-shrink: 0;
    padding: 8px 12px;
  }

  .projects {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 36px;
  }

  h1 {
    font-size: 3.45rem;
  }

  h2 {
    font-size: 2.35rem;
  }

  .mission-grid,
  .skills-grid,
  .achievement-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .education-timeline::before {
    left: 9px;
  }

  .education-card,
  .education-card:nth-child(odd),
  .education-card:nth-child(even) {
    width: calc(100% - 34px);
    justify-self: end;
  }

  .education-card:nth-child(odd) .timeline-dot,
  .education-card:nth-child(even) .timeline-dot {
    left: -34px;
    right: auto;
  }
}

@media (max-width: 620px) {
  .section-shell,
  .site-header,
  footer {
    width: min(100% - 28px, 1120px);
  }

  h1 {
    font-size: 2.85rem;
  }

  h2 {
    font-size: 2rem;
  }

  .signal-grid,
  .mission-grid,
  .skills-grid,
  .achievement-grid {
    grid-template-columns: 1fr;
  }

  .project-card {
    padding: 22px;
  }

  .about-section {
    padding-top: 56px;
    padding-bottom: 56px;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .about-text {
    max-width: 100%;
  }

  .about-text h2 {
    font-size: 1.85rem;
  }

  .about-text p {
    font-size: 1rem;
    line-height: 1.9;
  }

  .about-photo {
    justify-content: center;
  }

  .about-photo img {
    max-width: 260px;
  }

  .panel-header,
  .profile-readout p,
  footer {
    flex-direction: column;
  }

  .panel-header,
  .profile-name {
    margin-bottom: 48px;
  }

  .profile-name strong {
    font-size: 1.85rem;
  }
}
