@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=Space+Mono:wght@400;700&display=swap');

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

:root {
  --bg: #060608;
  --bg2: #0c0c12;
  --border: rgba(255,255,255,.06);
  --text: #e4e4ec;
  --muted: #6b6b80;
  --orange: #f7931a;
  --gold: #ffc847;
  --cyan: #00d4ff;
  --green: #00e676;
  --red: #ff5252;
  --glow-o: rgba(247,147,26,.15);
  --glow-c: rgba(0,212,255,.1);
  --grad: linear-gradient(135deg, var(--orange), var(--gold));
  --grad-c: linear-gradient(135deg, var(--cyan), #7b61ff);
  --radius: 16px;
  --ease: cubic-bezier(.16,1,.3,1);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Space Grotesk', sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  line-height: 1.6;
}

::selection { background: var(--orange); color: #000; }

/* ═══════════ 3D CANVAS ═══════════ */

#bg3d {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* ═══════════ CHAIN CANVAS ═══════════ */

#chainCanvas {
  position: fixed;
  left: 0;
  top: 0;
  width: 120px;
  height: 100%;
  z-index: 50;
  pointer-events: none;
}

/* ═══════════ TICKER NAV ═══════════ */

.ticker {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  padding: 10px 0;
  background: rgba(6,6,8,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.ticker:hover .ticker-track { animation-play-state: paused; }

.ticker-track {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  animation: tickScroll 40s linear infinite;
  width: max-content;
}

.t-nav {
  white-space: nowrap;
  font-family: 'Space Mono', monospace;
  font-size: .8rem;
  font-weight: 400;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: .04em;
  text-transform: uppercase;
  transition: color .3s;
  padding: 2px 0;
}

.t-nav:hover { color: var(--orange); }

.t-nav.logo {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  text-transform: none;
  letter-spacing: 0;
}

.t-nav.logo span { color: var(--orange); }

.t-sep {
  color: rgba(247,147,26,.3);
  font-size: .5rem;
  user-select: none;
}

@keyframes tickScroll { to { transform: translateX(-50%); } }

/* ═══════════ MOBILE HEADER ═══════════ */

.mobile-header {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  padding: 0 1.5rem;
  height: 52px;
  align-items: center;
  justify-content: space-between;
  background: rgba(6,6,8,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.logo {
  font-family: 'Space Mono', monospace;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}

.logo span { color: var(--orange); }

.burger {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 201;
  padding: 4px;
}

.burger span { display: block; width: 26px; height: 2px; background: var(--text); transition: all .3s; transform-origin: center; }
.burger.open span:first-child { transform: rotate(45deg) translate(3px, 3px); }
.burger.open span:last-child { transform: rotate(-45deg) translate(3px, -3px); }

.mobile-nav {
  position: fixed;
  inset: 0;
  background: rgba(6,6,8,.97);
  backdrop-filter: blur(30px);
  z-index: 99;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s;
}

.mobile-nav.open { opacity: 1; pointer-events: all; }

.mobile-nav a {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  opacity: 0;
  transform: translateY(20px);
  transition: all .4s var(--ease), color .3s;
}

.mobile-nav.open a { opacity: 1; transform: translateY(0); }
.mobile-nav.open a:nth-child(1) { transition-delay: .05s; }
.mobile-nav.open a:nth-child(2) { transition-delay: .1s; }
.mobile-nav.open a:nth-child(3) { transition-delay: .15s; }
.mobile-nav.open a:nth-child(4) { transition-delay: .2s; }
.mobile-nav.open a:nth-child(5) { transition-delay: .25s; }
.mobile-nav a:hover { color: var(--orange); }

/* ═══════════ HERO ═══════════ */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 2;
  padding: 5rem 3rem 3rem 120px;
}

.hero-inner { max-width: 800px; }

.hero-pre {
  font-family: 'Space Mono', monospace;
  font-size: .75rem;
  color: var(--orange);
  letter-spacing: .15em;
  margin-bottom: 1.5rem;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp .8s var(--ease) .3s forwards;
}

.hero-name {
  margin-bottom: 1.5rem;
}

.hero-name .line {
  display: block;
  font-size: clamp(3.5rem, 10vw, 8rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -.03em;
  opacity: 0;
  transform: translateY(60px);
  animation: fadeUp .8s var(--ease) forwards;
}

.hero-name .line:nth-child(1) { animation-delay: .5s; }
.hero-name .line:nth-child(2) { animation-delay: .65s; }

.dot { color: var(--orange); }

.hero-tags {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.tag {
  font-size: .9rem;
  color: var(--muted);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp .6s var(--ease) .9s forwards;
}

.tag-sep {
  color: var(--orange);
  opacity: 0;
  animation: fadeUp .6s var(--ease) .95s forwards;
}

.cta {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  padding: .9rem 1.8rem;
  border: 1px solid var(--orange);
  border-radius: 100px;
  color: var(--orange);
  text-decoration: none;
  font-size: .9rem;
  font-weight: 500;
  position: relative;
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp .6s var(--ease) 1.1s forwards;
  transition: color .4s, border-color .4s;
}

.cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .5s var(--ease);
  z-index: -1;
  border-radius: inherit;
}

.cta:hover { color: #000; border-color: var(--gold); }
.cta:hover::before { transform: scaleX(1); transform-origin: left; }

.cta-arrow {
  display: flex;
  transition: transform .3s;
}

.cta:hover .cta-arrow { transform: translate(3px, -3px); }

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 120px;
  display: flex;
  align-items: center;
  gap: .75rem;
  opacity: 0;
  animation: fadeUp .6s var(--ease) 1.4s forwards;
}

.scroll-hint span {
  font-family: 'Space Mono', monospace;
  font-size: .65rem;
  color: var(--muted);
  letter-spacing: .1em;
  text-transform: uppercase;
}

.scroll-bar {
  width: 40px;
  height: 2px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}

.scroll-thumb {
  width: 50%;
  height: 100%;
  background: var(--orange);
  border-radius: 2px;
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

/* ═══════════ SECTIONS ═══════════ */

.sect {
  position: relative;
  z-index: 2;
  padding: 8rem 0;
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 3rem 0 120px; }

.sect-head {
  display: flex;
  align-items: baseline;
  gap: 1.5rem;
  margin-bottom: 4rem;
}

.sect-num {
  font-family: 'Space Mono', monospace;
  font-size: .75rem;
  color: var(--orange);
  letter-spacing: .1em;
}

.sect-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 700;
  letter-spacing: -.02em;
}

.big-text {
  font-size: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 1.5rem;
}

.big-text em {
  font-style: normal;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ═══════════ ABOUT ═══════════ */

.about-layout {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 4rem;
  align-items: start;
}

.about-left p {
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 1rem;
}

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

.counter-card {
  padding: 1.5rem 2rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all .4s var(--ease);
}

.counter-card:hover {
  border-color: rgba(247,147,26,.2);
  transform: translateX(8px);
}

.counter-card.accent { border-left: 2px solid var(--orange); }

.counter {
  font-family: 'Space Mono', monospace;
  font-size: 2.5rem;
  font-weight: 700;
  background: var(--grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.counter-plus {
  font-size: 1.5rem;
  color: var(--orange);
}

.counter-label {
  display: block;
  font-size: .8rem;
  color: var(--muted);
  margin-top: .25rem;
}

/* ═══════════ SKILLS ═══════════ */

.skills-row {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
}

.skill-pill {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .7rem 1.4rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: .9rem;
  cursor: default;
  transition: all .4s var(--ease);
  transform-style: preserve-3d;
  perspective: 600px;
}

.skill-pill:hover {
  border-color: rgba(247,147,26,.3);
  background: rgba(247,147,26,.05);
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(247,147,26,.08);
}

.skill-pill.highlight {
  border-color: rgba(247,147,26,.2);
  background: rgba(247,147,26,.04);
}

.skill-pill.highlight:hover {
  border-color: var(--orange);
  box-shadow: 0 8px 30px rgba(247,147,26,.15);
}

.sp-icon {
  font-family: 'Space Mono', monospace;
  font-size: .7rem;
  color: var(--orange);
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(247,147,26,.1);
  border-radius: 50%;
  flex-shrink: 0;
}

/* ═══════════ PROJECTS (HORIZONTAL) ═══════════ */

.projects-sect {
  padding-bottom: 4rem;
}

.h-scroll-wrap {
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 0 0 2rem 120px;
}

.h-scroll-wrap::-webkit-scrollbar { display: none; }

.h-track {
  display: flex;
  gap: 2rem;
  padding-right: 3rem;
  width: max-content;
}

.proj-card {
  width: 420px;
  flex-shrink: 0;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all .5s var(--ease);
  transform-style: preserve-3d;
  cursor: default;
}

.proj-card:hover {
  border-color: rgba(247,147,26,.25);
  transform: translateY(-6px);
  box-shadow: 0 20px 60px rgba(0,0,0,.4), 0 0 40px var(--glow-o);
}

.proj-visual {
  height: 220px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.v1 { background: linear-gradient(135deg, rgba(247,147,26,.08), rgba(255,200,71,.03)); }
.v2 { background: linear-gradient(135deg, rgba(0,212,255,.08), rgba(123,97,255,.03)); }
.v3 { background: linear-gradient(135deg, rgba(0,230,118,.08), rgba(0,212,255,.03)); }
.v4 { background: linear-gradient(135deg, rgba(123,97,255,.08), rgba(247,147,26,.03)); }

.proj-num {
  font-family: 'Space Mono', monospace;
  font-size: 5rem;
  font-weight: 700;
  opacity: .06;
  position: absolute;
  right: 1.5rem;
  bottom: -.5rem;
  line-height: 1;
}

.proj-deco {
  width: 100px;
  height: 100px;
  color: var(--orange);
  opacity: .25;
  animation: rotateSlow 20s linear infinite;
}

@keyframes rotateSlow { to { transform: rotate(360deg); } }

.proj-info { padding: 1.5rem; }

.proj-tags {
  display: flex;
  gap: .4rem;
  margin-bottom: .75rem;
}

.proj-tags span {
  font-family: 'Space Mono', monospace;
  font-size: .65rem;
  color: var(--orange);
  padding: .2rem .6rem;
  border: 1px solid rgba(247,147,26,.2);
  border-radius: 100px;
}

.proj-info h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: .5rem;
}

.proj-info p {
  font-size: .875rem;
  color: var(--muted);
  line-height: 1.6;
}

.h-scroll-progress {
  width: 200px;
  height: 2px;
  background: var(--border);
  margin: 1rem auto 0;
  border-radius: 2px;
  overflow: hidden;
}

.h-scroll-bar {
  width: 0%;
  height: 100%;
  background: var(--grad);
  border-radius: 2px;
  transition: width .1s;
}

/* ═══════════ EXPERIENCE ═══════════ */

.exp-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.exp-card {
  padding: 2rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all .4s var(--ease);
  transform-style: preserve-3d;
}

.exp-card:hover {
  border-color: rgba(247,147,26,.2);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(0,0,0,.3);
}

.exp-card.edu {
  border-left: 2px solid var(--cyan);
}

.exp-date {
  font-family: 'Space Mono', monospace;
  font-size: .7rem;
  color: var(--orange);
  letter-spacing: .05em;
}

.exp-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: .5rem 0 .25rem;
}

.exp-co {
  font-size: .85rem;
  color: var(--muted);
}

.exp-card p {
  font-size: .875rem;
  color: var(--muted);
  margin-top: .75rem;
  line-height: 1.6;
}

/* ═══════════ CONTACT ═══════════ */

.contact { padding-bottom: 4rem; }

.contact-inner p {
  color: var(--muted);
  font-size: 1.05rem;
  margin-bottom: 2rem;
  max-width: 500px;
}

.contact-row {
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.socials { display: flex; gap: .75rem; }

.socials a {
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--muted);
  transition: all .3s;
}

.socials a svg { width: 18px; height: 18px; }

.socials a:hover {
  color: var(--orange);
  border-color: var(--orange);
  transform: translateY(-3px);
  box-shadow: 0 4px 15px var(--glow-o);
}

.btc-bar {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  padding: .6rem 1rem;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-top: 2rem;
}

.btc-icon {
  color: var(--orange);
  font-size: 1.2rem;
  font-weight: 700;
}

.btc-bar code {
  font-family: 'Space Mono', monospace;
  font-size: .7rem;
  color: var(--muted);
  word-break: break-all;
}

.copy-btn {
  font-family: 'Space Mono', monospace;
  font-size: .65rem;
  color: var(--orange);
  background: rgba(247,147,26,.1);
  border: 1px solid rgba(247,147,26,.2);
  border-radius: 6px;
  padding: .3rem .6rem;
  cursor: pointer;
  transition: all .3s;
  white-space: nowrap;
}

.copy-btn:hover {
  background: rgba(247,147,26,.2);
}

/* ═══════════ FOOTER ═══════════ */

footer {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--border);
  padding: 1.5rem 0;
}

.foot-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .8rem;
  color: var(--muted);
}

.to-top {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--muted);
  text-decoration: none;
  transition: all .3s;
}

.to-top:hover {
  color: var(--orange);
  border-color: var(--orange);
  transform: translateY(-3px);
}

/* ═══════════ SCROLL REVEAL ═══════════ */

.reveal-on-scroll {
  opacity: 0;
  transform: translateY(40px);
  transition: all .7s var(--ease);
}

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

/* ═══════════ RESPONSIVE ═══════════ */

@media (max-width: 1024px) {
  .about-layout { grid-template-columns: 1fr; gap: 3rem; }
  .about-right { flex-direction: row; flex-wrap: wrap; }
  .counter-card { flex: 1; min-width: 140px; }
}

@media (max-width: 768px) {
  #chainCanvas { display: none; }
  .ticker { display: none; }
  .mobile-header { display: flex; }
  .hero { padding: 5rem 1.5rem 3rem; }
  .container { padding: 0 1.5rem; }
  .h-scroll-wrap { padding-left: 1.5rem; }
  .scroll-hint { left: 1.5rem; }
  .proj-card { width: 320px; }
  .exp-grid { grid-template-columns: 1fr; }
  .btc-bar { flex-wrap: wrap; }
}

@media (max-width: 420px) {
  .hero-tags { flex-direction: column; align-items: flex-start; gap: .25rem; }
  .tag-sep { display: none; }
  .proj-card { width: 280px; }
  .counter-card { min-width: 100%; }
}
