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

:root {
  --bg:         #0d0d0f;
  --surface:    #141417;
  --surface2:   #1a1a1f;
  --border:     #242429;
  --text:       #e2e2e8;
  --muted:      #7a7a8c;
  --grad:       linear-gradient(135deg, #f97316, #ec4899, #a855f7);
  --grad-text:  linear-gradient(135deg, #fb923c, #f472b6, #c084fc);
  --radius:     10px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Mono', monospace;
  font-size: 15px;
  line-height: 1.7;
  min-height: 100vh;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 48px;
  background: rgba(13,13,15,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 17px;
  line-height: 1;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.3px;
}
.nav-links {
  display: flex;
  gap: 36px;
  list-style: none;
}
.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text); }

/* ── HERO ── */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 120px max(48px, calc(50% - 720px)) 80px;
  position: relative;
  overflow: hidden;
  gap: 56px;
}
.hero-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.hero-bottom {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.9s;
}
.hero-panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: border-color 0.2s;
}
.hero-panel--featured {
  cursor: pointer;
}
.hero-panel--featured:hover {
  border-color: #a855f7;
}
.hero-right-inner {
  width: 100%;
}
.hero-featured-card {
  padding: 0;
  margin-bottom: 0;
  cursor: pointer;
}
.hero-featured-card:hover .hero-featured-name { color: #c084fc; }
.hero-featured-name {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.3px;
  color: var(--text);
  margin: 6px 0 8px;
}
.hero-featured-desc {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 12px;
}
.hero-right-divider {
  height: 1px;
  background: var(--border);
  margin: 28px 0;
}
.hero-right-label {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 16px;
}
.hero-right-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.hero-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.55s;
}
.hero-about-text {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
  margin-bottom: 16px;
}
.hero-about-looking {
  color: var(--text);
  font-size: 13px;
  margin-bottom: 24px;
}
.hero-about-cv {
  font-size: 12px;
  padding: 10px 20px;
}
.hero::before {
  content: '';
  position: absolute;
  top: -200px; right: -200px;
  width: 700px; height: 700px;
  background: radial-gradient(circle, rgba(168,85,247,0.07) 0%, transparent 70%);
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -100px; left: -100px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(249,115,22,0.05) 0%, transparent 70%);
  pointer-events: none;
}
.hero-eyebrow {
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 20px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.1s;
}
.hero-title {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: clamp(56px, 8vw, 130px);
  line-height: 1;
  letter-spacing: -3px;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.25s;
}
.hero-subtitle {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  font-size: clamp(18px, 2.2vw, 30px);
  line-height: 1.2;
  letter-spacing: -0.5px;
  color: var(--text);
  margin-top: 10px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.4s;
}
.hero-desc {
  margin-top: 16px;
  max-width: 520px;
  color: var(--muted);
  font-size: 13px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.42s;
}
.hero-cta {
  margin-top: 28px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 0.7s;
}
.btn {
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  padding: 12px 28px;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  letter-spacing: 0.05em;
  display: inline-block;
}
.btn-primary {
  background: var(--grad);
  color: #fff;
  border: none;
}
.btn-primary:hover { opacity: 0.85; transform: translateY(-1px); }
.btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--border);
}
.btn-ghost:hover { border-color: var(--muted); color: var(--text); transform: translateY(-1px); }

.hero-scroll-hint {
  position: absolute;
  bottom: 36px;
  left: 48px;
  font-size: 11px;
  letter-spacing: 0.15em;
  color: var(--border);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero-scroll-hint::before {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--border);
}

/* ── SECTIONS ── */
section { padding: 96px 48px; }
.section-label {
  font-size: 11px;
  letter-spacing: 0.25em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 12px;
}
.section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -1px;
  margin-bottom: 48px;
}
.grad-word {
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── ABOUT ── */
#about { border-top: 1px solid var(--border); }
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}
.about-skills { order: -1; }
.about-text p {
  color: var(--muted);
  margin-bottom: 16px;
  font-size: 14px;
}
.about-text p span { color: var(--text); }
.stack-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.stack-tag {
  font-size: 12px;
  padding: 5px 12px;
  border-radius: 4px;
  border: 1px solid var(--border);
  color: var(--muted);
  background: var(--surface);
  transition: all 0.2s;
}
.stack-tag:hover { border-color: #a855f7; color: var(--text); }
.stack-primary {
  border-color: rgba(168,85,247,0.3);
  color: #c084fc;
}

/* ── PROJECTS ── */
#projects { border-top: 1px solid var(--border); }
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}
.project-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}
.project-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad);
  opacity: 0;
  transition: opacity 0.3s;
  border-radius: var(--radius);
}
.project-card:hover {
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(0,0,0,0.4);
}
.project-card:hover::before { opacity: 0.06; }
.project-card > * { position: relative; z-index: 1; }

.project-type {
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 12px;
}
.project-name {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.4px;
  margin-bottom: 10px;
  color: var(--text);
}
.project-desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 20px;
}
.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.project-tag {
  font-size: 11px;
  padding: 3px 9px;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 3px;
  color: var(--muted);
}
.project-arrow {
  position: absolute;
  bottom: 24px;
  right: 24px;
  width: 32px; height: 32px;
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.project-card:hover .project-arrow {
  background: var(--grad);
  border-color: transparent;
}
.project-arrow svg { width: 14px; height: 14px; fill: none; stroke: var(--muted); stroke-width: 2; }
.project-card:hover .project-arrow svg { stroke: #fff; }

/* ── CONTACT ── */
#contact { border-top: 1px solid var(--border); }
.contact-inner {
  max-width: 600px;
}
.contact-inner p {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 32px;
}
.contact-links {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.contact-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  font-size: 14px;
  margin-bottom: 8px;
  background: var(--surface);
  transition: all 0.2s;
}
.contact-link:hover {
  border-color: #a855f7;
  background: rgba(168,85,247,0.05);
  transform: translateX(4px);
}
.contact-link-label { color: var(--muted); font-size: 12px; }
.contact-link-val { font-family: 'Space Grotesk', sans-serif; font-weight: 600; font-size: 15px; }

/* ── FOOTER ── */
footer {
  border-top: 1px solid var(--border);
  padding: 32px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 15px;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.footer-note { font-size: 12px; color: var(--border); }

/* ── MODAL ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  backdrop-filter: blur(6px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}
.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.modal {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  max-width: 640px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 40px;
  position: relative;
  transform: translateY(20px);
  transition: transform 0.3s;
}
.modal-overlay.open .modal { transform: translateY(0); }
.modal-close {
  position: absolute;
  top: 20px; right: 20px;
  width: 32px; height: 32px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  transition: all 0.2s;
}
.modal-close:hover { border-color: var(--muted); color: var(--text); }
.modal-type {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}
.modal-title {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 28px;
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}
.modal-tagline {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
}
.modal-body {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}
.modal-body p { margin-bottom: 14px; }
.modal-body strong { color: var(--text); font-weight: 400; }
.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.modal-links {
  display: flex;
  gap: 12px;
  margin-top: 28px;
}

/* ── SCROLL REVEAL ── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-left {
  opacity: 0;
  transform: translateX(-24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}
.reveal-right {
  opacity: 0;
  transform: translateX(24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

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

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  nav { padding: 16px 24px; }
  .nav-links { gap: 24px; }
  .hero { padding: 100px 24px 60px; gap: 40px; }
  .hero-bottom { grid-template-columns: 1fr; }
  .hero-top { align-items: flex-start; text-align: left; }
  .hero-stack { justify-content: flex-start; }
  .hero-cta { justify-content: flex-start; }
  section { padding: 72px 24px; }
  footer { padding: 28px 24px; flex-direction: column; gap: 12px; text-align: center; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-skills { order: 0; }
  .hero-scroll-hint { left: 24px; }
  .modal { padding: 28px 24px; }
}
