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

:root {
  --bg: #080810;
  --surface: #0f0f1a;
  --card: #13131f;
  --border: rgba(255,255,255,0.07);
  --accent: #7dffd8;
  --accent2: #ff6bcd;
  --white: #f0f0f8;
  --muted: #6b6b8a;
  --font-display: 'Syne', sans-serif;
  --font-mono: 'DM Mono', monospace;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--font-display);
  overflow-x: hidden;
  cursor: none;
}

/* ── CURSOR ───────────────────────────────── */
.cursor {
  position: fixed;
  width: 12px; height: 12px;
  background: var(--accent);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.1s, width 0.2s, height 0.2s, opacity 0.2s;
  mix-blend-mode: difference;
}
.cursor-ring {
  position: fixed;
  width: 36px; height: 36px;
  border: 1px solid var(--accent);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  transform: translate(-50%, -50%);
  transition: left 0.12s ease, top 0.12s ease, width 0.2s, height 0.2s;
  opacity: 0.5;
}

/* ── NOISE OVERLAY ────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 1;
  opacity: 0.35;
}

/* ── GRID LINES BACKGROUND ────────────────── */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(125,255,216,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(125,255,216,0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

/* ── NAVIGATION ───────────────────────────── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 3rem;
  background: rgba(8,8,16,0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  letter-spacing: 0.05em;
}

.nav-links { display: flex; gap: 2.5rem; list-style: none; }
.nav-links a {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--accent); }

/* ── HERO ─────────────────────────────────── */
.hero {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 8rem 3rem 4rem;
  max-width: 1200px;
  margin: 0 auto;
}

.hero-tag {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 2rem;
  opacity: 0;
  animation: fadeUp 0.7s 0.2s forwards;
}

.hero-name {
  font-size: clamp(3.5rem, 9vw, 8rem);
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.35s forwards;
}

.hero-name .line2 {
  display: block;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.3);
}

.hero-desc {
  max-width: 520px;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  line-height: 1.8;
  color: var(--muted);
  margin-bottom: 3rem;
  opacity: 0;
  animation: fadeUp 0.8s 0.5s forwards;
}

.hero-desc em { color: var(--accent); font-style: normal; }

.hero-cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeUp 0.8s 0.65s forwards;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.8rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 3px;
  transition: all 0.2s;
  cursor: none;
}

.btn-primary {
  background: var(--accent);
  color: #08080f;
  font-weight: 500;
}
.btn-primary:hover {
  background: #fff;
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(125,255,216,0.3);
}

.btn-outline {
  border: 1px solid var(--border);
  color: var(--muted);
}
.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* ── HERO BADGE ───────────────────────────── */
.hero-badge {
  position: absolute;
  right: 3rem;
  top: 50%;
  transform: translateY(-50%);
  width: 200px; height: 200px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--muted);
  line-height: 1.8;
  letter-spacing: 0.08em;
  opacity: 0;
  animation: fadeIn 1.2s 1s forwards, spin 30s 1.2s linear infinite;
}

.hero-badge::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  border: 1px dashed rgba(125,255,216,0.2);
  animation: spin 25s linear infinite reverse;
}

.hero-scroll {
  position: absolute;
  bottom: 3rem;
  left: 3rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 1rem;
  opacity: 0;
  animation: fadeUp 0.8s 1.2s forwards;
}

.hero-scroll::before {
  content: '';
  width: 40px; height: 1px;
  background: var(--muted);
  display: block;
}

/* ── STATS BAR ────────────────────────────── */
.stats-bar {
  position: relative;
  z-index: 2;
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 2.5rem 3rem;
}

.stats-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  text-align: center;
}

.stat-num {
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--white);
  display: block;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-num span { color: var(--accent); }

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

/* ── SECTION COMMON ───────────────────────── */
section {
  position: relative;
  z-index: 2;
  padding: 6rem 3rem;
  max-width: 1200px;
  margin: 0 auto;
}

.section-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}
.section-tag::after {
  content: '';
  flex: 1;
  max-width: 60px;
  height: 1px;
  background: var(--accent);
  opacity: 0.4;
}

.section-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 3.5rem;
}

/* ── PROJECTS ─────────────────────────────── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 1.5px;
  background: var(--border);
  border: 1px solid var(--border);
}

.project-card {
  background: var(--card);
  padding: 3rem;
  transition: background 0.3s;
  position: relative;
  overflow: hidden;
}

.project-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), var(--accent2));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.project-card:hover::before { transform: scaleX(1); }
.project-card:hover { background: #16162a; }

.project-card--wide {
  grid-column: 1 / -1;
  background: #0c0c18;
}

.project-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--muted);
  margin-bottom: 2rem;
  letter-spacing: 0.1em;
}

.project-name {
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
  line-height: 1.1;
}

.project-name--sm { font-size: 1.4rem; }

.project-desc {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.9;
  margin-bottom: 2rem;
}

.project-desc--wide { max-width: 600px; }

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  padding: 0.3rem 0.75rem;
  border: 1px solid var(--border);
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 2px;
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: gap 0.2s;
}
.project-link:hover { gap: 0.9rem; }

/* ── SKILLS ───────────────────────────────── */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
}

.skill-group {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 2rem;
  border-radius: 4px;
  transition: border-color 0.3s;
}

.skill-group:hover { border-color: rgba(125,255,216,0.2); }

.skill-group-title {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 1.2rem;
}

.skill-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.skill-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--muted);
}

.skill-dot {
  width: 5px; height: 5px;
  background: var(--accent);
  border-radius: 50%;
  flex-shrink: 0;
}

/* ── ABOUT ────────────────────────────────── */
.about-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: start;
}

.about-text {
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: var(--muted);
  line-height: 2;
}

.about-text p { margin-bottom: 1.5rem; }
.about-text em { color: var(--accent); font-style: normal; }

.about-right {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.about-fact {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-left: 2px solid var(--accent);
  background: var(--card);
}

.about-fact-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}

.about-fact-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
}

/* ── CONTACT ──────────────────────────────── */
.contact-section {
  background: var(--surface);
  border-top: 1px solid var(--border);
}

.contact-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 6rem 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.contact-big {
  font-size: clamp(2rem, 5vw, 5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 1.5rem;
}

.contact-big span { color: var(--accent); }

.contact-sub {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 3rem;
  max-width: 480px;
  line-height: 1.8;
}

.contact-email {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  color: var(--white);
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
  padding-bottom: 0.2rem;
  transition: color 0.2s;
  cursor: none;
}

.contact-email:hover { color: var(--accent); }

/* ── FOOTER ───────────────────────────────── */
footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--border);
  padding: 2rem 3rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg);
}

footer span {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}

/* ── ANIMATIONS ───────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 0.6; }
}

@keyframes spin {
  to { transform: translateY(-50%) rotate(360deg); }
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s, transform 0.7s;
}

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

/* ── RESPONSIVE ───────────────────────────── */
@media (max-width: 768px) {
  nav { padding: 1.2rem 1.5rem; }
  .nav-links { display: none; }
  .hero { padding: 7rem 1.5rem 3rem; }
  .hero-badge { display: none; }
  section { padding: 4rem 1.5rem; }
  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .about-inner { grid-template-columns: 1fr; gap: 3rem; }
  footer { flex-direction: column; gap: 0.5rem; text-align: center; }
  .projects-grid { grid-template-columns: 1fr; }
}