:root {
  --bg: #08090d;
  --surface: #101116;
  --surface-2: #15171e;
  --surface-3: #1b1d26;
  --text: #f4f3f7;
  --muted: #9a9aa5;
  --purple: #a78bfa;
  --purple-strong: #7c3aed;
  --blue: #6ca7ff;
  --border: rgba(255, 255, 255, 0.08);
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}
body.modal-open { overflow: hidden; }
button, a { font: inherit; }
a { color: inherit; text-decoration: none; }
button { color: inherit; }
.container { width: min(calc(100% - 40px), var(--container)); margin-inline: auto; }
.skip-link { position: fixed; left: 12px; top: -50px; z-index: 100; background: white; color: black; padding: 8px 12px; }
.skip-link:focus { top: 12px; }
.scroll-progress { position: fixed; z-index: 60; inset: 0 0 auto; height: 2px; pointer-events: none; background: transparent; }
.scroll-progress span { display: block; width: 100%; height: 100%; transform: scaleX(0); transform-origin: left; background: linear-gradient(90deg, #8c69ef, #69a9ff, #9e8cff); box-shadow: 0 0 12px rgba(130,112,255,.65); will-change: transform; }

.ambient { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.orb { position: absolute; width: 420px; height: 420px; border-radius: 50%; filter: blur(110px); opacity: .11; }
.orb-one { top: 80px; right: -140px; background: #7c3aed; }
.orb-two { bottom: 10%; left: -180px; background: #2563eb; }
.grid { position: absolute; inset: 0; opacity: .16; background-image: linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px); background-size: 48px 48px; mask-image: linear-gradient(to bottom, black, transparent 75%); }

.site-header { position: sticky; top: 0; z-index: 50; border-bottom: 1px solid transparent; backdrop-filter: blur(14px); transition: .3s ease; }
.site-header.scrolled { background: rgba(8,9,13,.82); border-bottom-color: var(--border); }
.nav { height: 76px; display: flex; align-items: center; gap: 30px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; letter-spacing: -.02em; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--border); border-radius: 10px; background: linear-gradient(135deg, rgba(167,139,250,.18), rgba(108,167,255,.08)); color: #c4b5fd; font-size: 12px; }
.nav-links { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.nav-links a { color: #babac4; font-size: 14px; transition: color .2s; }
.nav-links a:hover, .nav-links a:focus-visible { color: white; }
.nav-cta { margin-left: 6px; }
.nav-toggle { display: none; border: 0; background: none; padding: 8px; }
.nav-toggle span { display: block; width: 22px; height: 2px; margin: 4px; background: white; }

.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 0 18px; border: 1px solid var(--border); border-radius: 11px; font-weight: 700; font-size: 14px; transition: transform .2s, border-color .2s, background .2s, box-shadow .2s; }
.button:hover { transform: translateY(-2px); }
.button-primary { border: 0; background: linear-gradient(135deg, #9b7cf3, #7157d9); box-shadow: 0 12px 35px rgba(124,58,237,.24); }
.button-primary:hover { box-shadow: 0 16px 42px rgba(124,58,237,.34); }
.button-secondary { background: rgba(255,255,255,.025); }
.button-secondary:hover { border-color: rgba(167,139,250,.35); background: rgba(255,255,255,.05); }
.button-small { min-height: 40px; padding-inline: 15px; background: rgba(255,255,255,.04); }
.icon-button { width: 48px; height: 48px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 11px; background: rgba(255,255,255,.025); }

.hero { min-height: 680px; display: grid; grid-template-columns: 1.08fr .92fr; align-items: center; gap: 60px; padding-block: 70px 90px; }
.status-pill { width: fit-content; display: flex; align-items: center; gap: 9px; margin-bottom: 22px; padding: 7px 12px; border: 1px solid var(--border); border-radius: 999px; color: #bdbdca; background: rgba(255,255,255,.025); font-size: 12px; }
.status-pill span { width: 7px; height: 7px; border-radius: 50%; background: #5ee6a8; box-shadow: 0 0 12px #5ee6a8; }
.hero h1 { max-width: 700px; margin: 0; font-size: clamp(48px, 6vw, 78px); line-height: 1.04; letter-spacing: -.055em; }
.hero h1 > span:not(.headline-word) { background: linear-gradient(90deg, #a994f5 15%, #719cff 78%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-description { max-width: 600px; margin: 24px 0 30px; color: #aaaab5; font-size: 17px; }
.hero-actions { display: flex; align-items: center; gap: 10px; }
.tech-row { display: flex; gap: 9px; margin-top: 28px; }
.tech-badge { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; padding: 5px 10px 5px 6px; border: 1px solid var(--border); border-radius: 9px; background: rgba(255,255,255,.025); color: #bebec8; font-size: 12px; }
.tech-badge b { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 7px; font-size: 10px; }
.python { background: rgba(88,166,255,.16); color: #82baff; }
.javascript { background: rgba(247,223,30,.12); color: #f4df55; }
.html { background: rgba(255,108,62,.13); color: #ff986f; }

.hero-visual { position: relative; min-height: 430px; display: grid; place-items: center; }
.hero-canvas { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; pointer-events: none; }
.hero-visual.webgl-ready .scene { display: none; }
.hero-visual:not(.webgl-ready)::before, .hero-visual:not(.webgl-ready)::after { content: ""; position: absolute; z-index: 0; width: 270px; height: 270px; border: 1px solid rgba(167,139,250,.22); border-radius: 50%; transform: rotateX(65deg) rotateZ(-25deg); box-shadow: 0 0 55px rgba(124,58,237,.13), inset 0 0 35px rgba(108,167,255,.07); animation: ringSpinOne 18s linear infinite; }
.hero-visual:not(.webgl-ready)::after { width: 215px; height: 215px; border-color: rgba(108,167,255,.28); transform: rotateY(65deg) rotateZ(20deg); animation: ringSpinTwo 14s linear infinite; }
.code-window { position: relative; width: 100%; max-width: 500px; border: 1px solid rgba(255,255,255,.09); border-radius: 16px; background: rgba(15,16,21,.94); box-shadow: 0 35px 80px rgba(0,0,0,.48), 0 0 80px rgba(124,58,237,.06); overflow: hidden; transform: perspective(1000px) rotateY(-4deg) rotateX(1deg); }
.code-window::after { content: ""; position: absolute; inset: -40% auto -40% -65%; width: 38%; pointer-events: none; background: linear-gradient(90deg, transparent, rgba(190,180,255,.055), transparent); transform: skewX(-18deg); animation: glassSweep 8s ease-in-out infinite; }
.code-window { z-index: 2; }
.window-bar { height: 48px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 0 14px; border-bottom: 1px solid var(--border); color: #777783; font-size: 11px; }
.window-dots { display: flex; gap: 6px; }
.window-dots i { width: 8px; height: 8px; border-radius: 50%; background: #3a3b44; }
.window-dots i:first-child { background: #b56161; }.window-dots i:nth-child(2) { background: #b69259; }.window-dots i:nth-child(3) { background: #5d9c78; }
.window-menu { justify-self: end; }
.code-body { padding: 30px 26px 36px; font-family: "SFMono-Regular", Consolas, monospace; font-size: 14px; }
.code-line { min-height: 32px; white-space: nowrap; }
.line-no { display: inline-block; width: 28px; color: #4c4d57; user-select: none; }
.pink { color: #d39aef; }.cyan { color: #82caff; }.green { color: #a8d98a; }.muted { color: #6d6e78; }
.output { margin-top: 8px; }.cursor { display: inline-block; width: 7px; height: 16px; margin-left: 5px; vertical-align: -3px; background: #a78bfa; animation: blink 1.1s step-end infinite; }
.floating-card { position: absolute; display: flex; align-items: center; gap: 10px; min-width: 168px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: rgba(23,24,31,.94); box-shadow: 0 20px 40px rgba(0,0,0,.35); backdrop-filter: blur(12px); }
.floating-card > span { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 9px; background: rgba(167,139,250,.12); }
.floating-card b, .floating-card small { display: block; }.floating-card b { font-size: 12px; }.floating-card small { color: var(--muted); font-size: 10px; }
.card-bots { left: -26px; bottom: 38px; }.card-code { right: -26px; top: 48px; }
@keyframes blink { 50% { opacity: 0; } }
@keyframes glassSweep { 0%, 58% { left: -65%; } 82%, 100% { left: 135%; } }

.section { padding-block: 100px; scroll-margin-top: 70px; }
.section-heading { margin-bottom: 44px; }
.section-heading-row { display: flex; align-items: end; justify-content: space-between; gap: 30px; }
.section-heading-row > p { max-width: 430px; color: var(--muted); font-size: 14px; }
.eyebrow { display: block; margin-bottom: 10px; color: #8d71df; font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.section h2 { margin: 0; font-size: clamp(34px, 4vw, 52px); line-height: 1.1; letter-spacing: -.04em; }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 70px; align-items: start; }
.about-copy { color: #b1b1bc; }.about-copy p { margin: 0 0 18px; }.text-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; color: #c6b8f7; font-size: 14px; font-weight: 700; }.text-link span { transition: transform .2s; }.text-link:hover span { transform: translateX(4px); }
.interest-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.interest-card { min-height: 120px; padding: 18px; border: 1px solid var(--border); border-radius: 14px; background: linear-gradient(145deg, rgba(255,255,255,.035), rgba(255,255,255,.015)); }
.interest-card span { display: block; margin-bottom: 12px; color: #9d82ec; font-size: 20px; }.interest-card h3 { margin: 0 0 4px; font-size: 14px; }.interest-card p { margin: 0; color: var(--muted); font-size: 12px; }

.skills-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.skill-card { min-height: 150px; padding: 18px; border: 1px solid var(--border); border-radius: 14px; background: linear-gradient(145deg, rgba(255,255,255,.032), rgba(255,255,255,.012)); transition: transform .25s, border-color .25s; }
.skill-card:hover { transform: translateY(-5px); border-color: rgba(167,139,250,.28); }
.skill-icon { width: 44px; height: 44px; display: grid; place-items: center; margin-bottom: 22px; border: 1px solid var(--border); border-radius: 10px; background: rgba(167,139,250,.08); color: #c1b2ef; font-weight: 800; }
.skill-card h3 { margin: 0; font-size: 14px; }.skill-level { display: block; margin-top: 5px; color: var(--muted); font-size: 11px; }

.featured { background: linear-gradient(180deg, rgba(255,255,255,.018), transparent); border-block: 1px solid rgba(255,255,255,.035); }
.featured-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.project-card { position: relative; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); overflow: hidden; transition: transform .25s, border-color .25s, box-shadow .25s; }
.project-card:hover { transform: translateY(-5px); border-color: rgba(167,139,250,.24); box-shadow: 0 20px 50px rgba(0,0,0,.22); }
.featured-card { min-height: 410px; }
.project-preview { position: relative; height: 210px; overflow: hidden; background: var(--surface-2); }
.featured-card .project-preview { height: 260px; }
.project-preview img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.project-card:hover .project-preview img { transform: scale(1.025); }
.placeholder-preview { height: 100%; display: grid; place-items: center; position: relative; background: radial-gradient(circle at 75% 20%, rgba(167,139,250,.18), transparent 30%), linear-gradient(135deg, #171925, #101116); }
.placeholder-preview::before { content: ""; position: absolute; inset: 0; opacity: .18; background-image: linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px); background-size: 28px 28px; }
.placeholder-icon { width: 82px; height: 82px; z-index: 1; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.1); border-radius: 22px; background: rgba(167,139,250,.11); box-shadow: 0 18px 45px rgba(0,0,0,.28); color: #c6b7f5; font-size: 27px; }
.project-content { padding: 18px; }
.project-category { color: #9d86e8; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.project-content h3 { margin: 5px 0 7px; font-size: 20px; letter-spacing: -.02em; }
.project-content p { min-height: 44px; margin: 0 0 16px; color: var(--muted); font-size: 13px; }
.project-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding-top: 14px; border-top: 1px solid var(--border); color: #aaaab5; font-size: 11px; }
.project-meta span { display: inline-flex; align-items: center; gap: 5px; }
.project-actions { display: flex; gap: 8px; margin-top: 14px; }
.card-button { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; padding: 0 12px; border: 1px solid var(--border); border-radius: 8px; background: rgba(255,255,255,.025); font-size: 12px; font-weight: 700; }
.card-button.primary { border-color: rgba(167,139,250,.25); background: rgba(167,139,250,.1); }
.card-click { position: absolute; inset: 0; border: 0; background: transparent; cursor: pointer; z-index: 2; }.card-click:focus-visible { outline: 2px solid var(--purple); outline-offset: -3px; }
.project-content { position: relative; z-index: 3; pointer-events: none; }.project-actions { pointer-events: auto; }

.refresh-button { border: 1px solid var(--border); border-radius: 9px; background: rgba(255,255,255,.025); min-height: 40px; padding: 0 12px; cursor: pointer; }.refresh-button.loading span { opacity: .7; }.refresh-button.loading { animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .55; } }
.filters { display: flex; gap: 8px; margin-bottom: 24px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.filter-button { flex: 0 0 auto; min-height: 38px; padding: 0 13px; border: 1px solid var(--border); border-radius: 999px; background: rgba(255,255,255,.025); color: #aaaab5; cursor: pointer; font-size: 12px; }.filter-button.active { border-color: rgba(167,139,250,.32); background: rgba(167,139,250,.12); color: #d7cdf8; }
.projects-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.projects-grid .project-preview { height: 180px; }
.status-message { display: none; margin: 10px 0 18px; padding: 14px 16px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--muted); font-size: 13px; }.status-message.visible { display: block; }.status-message.error { border-color: rgba(248,113,113,.2); color: #f0aaaa; }
.empty-state { grid-column: 1 / -1; min-height: 220px; display: grid; place-items: center; text-align: center; border: 1px dashed var(--border); border-radius: 16px; color: var(--muted); }.empty-state strong { display: block; color: var(--text); margin-bottom: 6px; }

.stats-panel { display: grid; grid-template-columns: .8fr 2fr; align-items: center; min-height: 180px; padding: 34px 38px; border: 1px solid var(--border); border-radius: 18px; background: linear-gradient(135deg, rgba(167,139,250,.06), rgba(108,167,255,.025)); }
.stats-heading h2 { font-size: 30px; }.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }.stat { min-height: 90px; display: grid; align-content: center; text-align: center; border-left: 1px solid var(--border); }.stat strong { font-size: 34px; line-height: 1; }.stat span { margin-top: 10px; color: var(--muted); font-size: 11px; }

.contact { padding-bottom: 80px; }
.contact-panel { min-height: 260px; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 40px; padding: 48px; border: 1px solid var(--border); border-radius: 20px; background: radial-gradient(circle at 85% 20%, rgba(124,58,237,.13), transparent 28%), var(--surface); }
.contact-panel h2 { max-width: 620px; }.contact-panel p { color: var(--muted); }
.contact-actions { display: grid; grid-template-columns: repeat(2, minmax(130px, 1fr)); gap: 8px; }.contact-link { min-height: 44px; display: flex; align-items: center; justify-content: center; padding-inline: 14px; border: 1px solid var(--border); border-radius: 9px; background: rgba(255,255,255,.025); font-size: 13px; font-weight: 700; }.contact-link.primary { background: linear-gradient(135deg, #9272e7, #6851ca); border: 0; }
.footer { border-top: 1px solid var(--border); }.footer-inner { min-height: 100px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }.footer p { color: var(--muted); font-size: 12px; }.back-top { width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: 9px; }

.project-modal { width: min(760px, calc(100% - 30px)); max-height: calc(100vh - 30px); padding: 0; border: 1px solid var(--border); border-radius: 18px; background: #111218; color: var(--text); box-shadow: 0 30px 100px rgba(0,0,0,.6); }.project-modal::backdrop { background: rgba(3,4,7,.78); backdrop-filter: blur(8px); }
.modal-shell { position: relative; }.modal-close { position: absolute; right: 12px; top: 12px; z-index: 5; width: 38px; height: 38px; border: 1px solid var(--border); border-radius: 9px; background: rgba(8,9,13,.85); cursor: pointer; font-size: 20px; }
.modal-preview { height: 250px; }.modal-body { padding: 28px; }.modal-body h2 { margin: 5px 0 10px; font-size: 34px; }.modal-description { color: #b1b1bc; }.modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 20px 0; }.modal-grid h3 { font-size: 14px; }.modal-grid ul { margin: 8px 0; padding-left: 18px; color: var(--muted); font-size: 13px; }.tag-list { display: flex; flex-wrap: wrap; gap: 7px; }.tag { padding: 5px 8px; border: 1px solid var(--border); border-radius: 7px; color: #bbb9c6; font-size: 11px; }.modal-actions { display: flex; flex-wrap: wrap; gap: 8px; }

@media (max-width: 980px) {
  .nav-links { gap: 18px; }.nav-cta { display: none; }
  .hero { grid-template-columns: 1fr; }.hero-copy { text-align: center; }.status-pill, .hero-description { margin-inline: auto; }.hero-actions, .tech-row { justify-content: center; }.hero-visual { width: min(600px, 100%); margin-inline: auto; }
  .skills-grid { grid-template-columns: repeat(3, 1fr); }.projects-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-panel { grid-template-columns: 1fr; gap: 24px; }.stats-heading { text-align: center; }
}
@media (max-width: 720px) {
  .container { width: min(calc(100% - 28px), var(--container)); }
  .nav { height: 68px; }.nav-toggle { display: block; margin-left: auto; }.nav-links { position: absolute; left: 14px; right: 14px; top: 62px; display: none; flex-direction: column; align-items: stretch; gap: 0; padding: 8px; border: 1px solid var(--border); border-radius: 12px; background: rgba(16,17,22,.98); }.nav-links.open { display: flex; }.nav-links a { padding: 12px; }
  .hero { min-height: auto; padding-block: 54px 70px; }.hero h1 { font-size: clamp(42px, 12vw, 58px); }.hero-description { font-size: 15px; }.hero-actions { flex-wrap: wrap; }.hero-visual { min-height: 360px; }.code-window { max-width: 520px; transform: none; }.code-body { font-size: 12px; padding-inline: 16px; }.floating-card { display: none; }
  .section { padding-block: 72px; }.section-heading-row { align-items: start; }.section-heading-row > p { display: none; }.about-grid { grid-template-columns: 1fr; gap: 28px; }.skills-grid { grid-template-columns: repeat(2, 1fr); }.featured-grid, .projects-grid { grid-template-columns: 1fr; }.featured-card { min-height: 390px; }.featured-card .project-preview { height: 230px; }
  .stats-panel { padding: 28px 18px; }.stats-grid { grid-template-columns: repeat(2, 1fr); }.stat { border: 0; border-bottom: 1px solid var(--border); }.contact-panel { grid-template-columns: 1fr; padding: 32px 24px; }.contact-actions { width: 100%; }
  .footer-inner { min-height: 130px; flex-wrap: wrap; }.footer-inner p { order: 3; width: 100%; }
  .modal-preview { height: 190px; }.modal-body { padding: 22px 18px; }.modal-grid { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  .brand { font-size: 14px; }.brand-mark { width: 32px; height: 32px; }.hero-actions .button { flex: 1 1 100%; }.icon-button { display: none; }.tech-row { flex-wrap: wrap; }.interest-grid { grid-template-columns: 1fr; }.skills-grid { grid-template-columns: 1fr 1fr; }.skill-card { min-height: 140px; }.contact-actions { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; } *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Premium motion layer */
.particle-canvas {
  position: fixed;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: .58;
}

.page-loader {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 18px;
  background: #08090d;
  transition: opacity .65s cubic-bezier(.22,1,.36,1), visibility .65s;
}
.page-loader.loaded { opacity: 0; visibility: hidden; }
.loader-mark {
  width: 76px;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 1px solid rgba(167,139,250,.22);
  border-radius: 22px;
  background: radial-gradient(circle, rgba(167,139,250,.16), rgba(15,16,21,.8));
  box-shadow: 0 0 55px rgba(124,58,237,.18);
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 13px;
  color: #c6b5ff;
  animation: loaderFloat 1.8s ease-in-out infinite;
}
.loader-mark i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #75aaff;
  box-shadow: 0 0 12px #75aaff;
  animation: loaderPulse .8s ease-in-out infinite alternate;
}
.loader-name { font-size: 13px; font-weight: 800; letter-spacing: .12em; }
.loader-track { width: 150px; height: 2px; overflow: hidden; background: rgba(255,255,255,.07); }
.loader-track span { display: block; width: 60%; height: 100%; background: linear-gradient(90deg, #7c3aed, #75aaff); animation: loaderSweep 1s ease-in-out infinite; }
@keyframes loaderFloat { 50% { transform: translateY(-7px) rotate(3deg); } }
@keyframes loaderPulse { to { transform: scale(1.8); opacity: .45; } }
@keyframes loaderSweep { from { transform: translateX(-100%); } to { transform: translateX(220%); } }

.cursor-glow {
  position: fixed;
  z-index: 45;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124,58,237,.09), transparent 68%);
  transform: translate(-50%, -50%);
  pointer-events: none;
  opacity: 0;
  transition: opacity .25s;
  mix-blend-mode: screen;
}
body.pointer-active .cursor-glow { opacity: 1; }

.hero-visual {
  transform-style: preserve-3d;
  perspective: 1000px;
}
.scene {
  position: absolute;
  z-index: 0;
  width: 330px;
  height: 330px;
  display: grid;
  place-items: center;
  pointer-events: none;
  filter: drop-shadow(0 25px 50px rgba(55,40,130,.24));
  animation: sceneFloat 7s ease-in-out infinite;
}
.scene-core {
  width: 150px;
  height: 150px;
  border: 1px solid rgba(188,173,255,.24);
  border-radius: 38px;
  background:
    linear-gradient(135deg, rgba(167,139,250,.25), rgba(108,167,255,.08)),
    radial-gradient(circle at 30% 25%, rgba(255,255,255,.17), transparent 25%);
  box-shadow: inset 0 0 35px rgba(167,139,250,.12), 0 0 70px rgba(124,58,237,.18);
  transform: rotate(32deg) perspective(500px) rotateX(18deg);
  animation: coreTurn 11s linear infinite;
}
.scene-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(167,139,250,.22);
  transform-style: preserve-3d;
}
.ring-one {
  width: 290px;
  height: 290px;
  transform: rotateX(68deg) rotateZ(18deg);
  box-shadow: 0 0 20px rgba(108,167,255,.08);
  animation: ringSpinOne 16s linear infinite;
}
.ring-two {
  width: 240px;
  height: 240px;
  border-color: rgba(108,167,255,.22);
  transform: rotateY(70deg) rotateZ(-12deg);
  animation: ringSpinTwo 13s linear infinite;
}
.code-window {
  z-index: 2;
  will-change: transform;
  background: linear-gradient(145deg, rgba(18,19,26,.96), rgba(11,12,17,.92));
  backdrop-filter: blur(16px);
}
.floating-card {
  z-index: 3;
  will-change: transform;
  animation: cardFloat 5s ease-in-out infinite;
}
.card-code { animation-delay: -2.4s; }
@keyframes sceneFloat { 50% { transform: translateY(-14px) scale(1.02); } }
@keyframes coreTurn { to { transform: rotate(392deg) perspective(500px) rotateX(18deg); } }
@keyframes ringSpinOne { to { transform: rotateX(68deg) rotateZ(378deg); } }
@keyframes ringSpinTwo { to { transform: rotateY(70deg) rotateZ(348deg); } }
@keyframes cardFloat { 50% { transform: translateY(-8px); } }

.hero h1 .headline-word,
.hero-description,
.hero-actions,
.tech-row,
.status-pill {
  opacity: 0;
  transform: translateY(18px);
  animation: contentEnter .8s cubic-bezier(.22,1,.36,1) forwards;
}
.hero h1 .headline-word { display: inline-block; margin-right: .18em; animation-delay: calc(var(--word-index) * 70ms + 180ms); }
.hero h1 .gradient-word {
  background: linear-gradient(90deg, #a994f5 15%, #719cff 78%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-description { animation-delay: 520ms; }
.hero-actions { animation-delay: 650ms; }
.tech-row { animation-delay: 760ms; }
.status-pill { animation-delay: 100ms; }
@keyframes contentEnter { to { opacity: 1; transform: translateY(0); } }

.reveal {
  opacity: 0;
  transform: perspective(1100px) translate3d(0, 64px, 0) rotateX(8deg) scale(.94);
  filter: blur(12px);
  clip-path: inset(8% 5% 8% 5% round 32px);
  transition: opacity 1s cubic-bezier(.16,1,.3,1), transform 1.15s cubic-bezier(.16,1,.3,1), filter 1s ease, clip-path 1.15s cubic-bezier(.16,1,.3,1);
  will-change: opacity, transform, filter, clip-path;
}
.reveal.visible { opacity: 1; transform: perspective(1100px) translate3d(0, 0, 0) rotateX(0) scale(1); filter: blur(0); clip-path: inset(0 0 0 0 round 0); }
.section-heading h2 { transform-origin: 0 100%; }
.reveal-stagger > * {
  opacity: 0;
  transform: perspective(900px) translate3d(0, 34px, -30px) rotateX(7deg) scale(.96);
  filter: blur(7px);
  transition: opacity .8s cubic-bezier(.16,1,.3,1), transform .9s cubic-bezier(.16,1,.3,1), filter .8s ease;
}
.reveal-stagger.visible > * { opacity: 1; transform: perspective(900px) translate3d(0, 0, 0) rotateX(0) scale(1); filter: blur(0); }
.reveal-stagger.visible > *:nth-child(2) { transition-delay: 70ms; }
.reveal-stagger.visible > *:nth-child(3) { transition-delay: 140ms; }
.reveal-stagger.visible > *:nth-child(4) { transition-delay: 210ms; }
.reveal-stagger.visible > *:nth-child(5) { transition-delay: 280ms; }
.reveal-stagger.visible > *:nth-child(6) { transition-delay: 350ms; }

.site-header {
  background: linear-gradient(180deg, rgba(8,9,13,.12), transparent);
}
.site-header.scrolled {
  background: rgba(8,9,13,.72);
  box-shadow: 0 12px 40px rgba(0,0,0,.12);
}
.nav-links a { position: relative; }
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -8px;
  height: 1px;
  background: linear-gradient(90deg, #a78bfa, #75aaff);
  transition: right .25s ease;
}
.nav-links a:hover::after,
.nav-links a.active::after { right: 0; }
.nav-links a.active { color: #e6e1f6; }

.button, .icon-button, .card-button, .contact-link, .filter-button {
  position: relative;
  overflow: hidden;
  transform-style: preserve-3d;
}
.button::before, .contact-link::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.12), transparent 70%);
  transform: translateX(-120%);
  transition: transform .65s;
}
.button:hover::before, .contact-link:hover::before { transform: translateX(120%); }

.project-card {
  --pointer-x: 50%;
  --pointer-y: 50%;
  transform-style: preserve-3d;
  will-change: transform;
  transition: transform .16s ease-out, border-color .25s, box-shadow .25s;
}
.project-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: radial-gradient(260px circle at var(--pointer-x) var(--pointer-y), rgba(167,139,250,.12), transparent 42%);
  transition: opacity .25s;
}
.project-card:hover::after { opacity: 1; }
.project-card.category-discord-bot { --category-accent: 167,139,250; }
.project-card.category-telegram-bot { --category-accent: 108,167,255; }
.project-card.category-android { --category-accent: 95,211,173; }
.project-card.category-python { --category-accent: 99,179,237; }
.project-card.category-javascript { --category-accent: 240,205,80; }
.project-card.category-web-app { --category-accent: 130,202,255; }
.project-card.category-other { --category-accent: 181,156,238; }
.project-card:hover {
  border-color: rgba(var(--category-accent, 167,139,250),.38);
  box-shadow: 0 28px 70px rgba(0,0,0,.34), 0 0 38px rgba(var(--category-accent, 167,139,250),.07);
}
.placeholder-preview {
  background:
    radial-gradient(circle at 75% 20%, rgba(var(--category-accent, 167,139,250),.18), transparent 34%),
    linear-gradient(135deg, #171925, #101116);
}
.placeholder-icon {
  box-shadow: 0 18px 45px rgba(0,0,0,.28), 0 0 40px rgba(var(--category-accent, 167,139,250),.10);
  animation: iconFloat 4.5s ease-in-out infinite;
}
.project-card:hover .project-preview img { transform: scale(1.06); }
.project-preview::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 35%, rgba(255,255,255,.07) 48%, transparent 60%);
  transform: translateX(-130%);
  transition: transform .9s cubic-bezier(.22,1,.36,1);
}
.project-card:hover .project-preview::after { transform: translateX(130%); }
@keyframes iconFloat { 50% { transform: translateY(-7px) rotate(3deg); } }

.skill-card {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  transform-style: preserve-3d;
  transition: transform .35s cubic-bezier(.22,1,.36,1), border-color .25s, box-shadow .25s;
  background:
    radial-gradient(ellipse at 88% 25%, hsla(var(--skill-hue, 260), 80%, 65%, .13), transparent 48%),
    linear-gradient(145deg, rgba(23,24,33,.96), rgba(12,13,18,.98));
}
.skill-art { position: absolute; z-index: -1; width: 78%; height: 100%; right: -7%; top: 0; background-image: var(--skill-art); background-repeat: no-repeat; background-position: right center; background-size: contain; opacity: .48; transform: translateX(5%) scale(.92); transition: opacity .4s ease, transform .6s cubic-bezier(.22,1,.36,1); }
.skill-card::after { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg, rgba(15,16,22,.98) 10%, rgba(15,16,22,.82) 46%, rgba(15,16,22,.1)); pointer-events: none; }
.skill-card > :not(.skill-art) { position: relative; z-index: 1; }
.skill-card::before {
  content: "";
  position: absolute;
  width: 130px;
  height: 130px;
  right: -90px;
  top: -90px;
  border-radius: 50%;
  background: rgba(167,139,250,.09);
  filter: blur(18px);
  transition: transform .5s;
}
.skill-card:hover { transform: translateY(-7px) rotateX(3deg); border-color: hsla(var(--skill-hue, 260), 80%, 70%, .4); box-shadow: 0 18px 40px rgba(0,0,0,.28), 0 0 34px hsla(var(--skill-hue, 260), 80%, 65%, .1); }
.skill-card:hover .skill-art { opacity: .78; transform: translateX(0) scale(1.04); }
.skill-card:hover::before { transform: translate(-12px, 12px) scale(1.3); }

.orb { animation: orbDrift 14s ease-in-out infinite alternate; }
.orb-two { animation-delay: -7s; }
.grid { transform: scale(1.05); }
@keyframes orbDrift { to { transform: translate3d(80px, 35px, 0) scale(1.12); } }

.stats-panel, .contact-panel {
  backdrop-filter: blur(18px);
  box-shadow: inset 0 1px rgba(255,255,255,.025), 0 25px 70px rgba(0,0,0,.12);
}

.project-modal[open] { animation: modalEnter .42s cubic-bezier(.22,1,.36,1); }
@keyframes modalEnter {
  from { opacity: 0; transform: translateY(18px) scale(.96) perspective(900px) rotateX(3deg); }
  to { opacity: 1; transform: translateY(0) scale(1) perspective(900px) rotateX(0); }
}

@media (max-width: 720px) {
  .cursor-glow { display: none; }
  .particle-canvas { opacity: .28; }
  .scene { width: 220px; height: 220px; opacity: .68; }
  .scene-core { width: 105px; height: 105px; border-radius: 28px; }
  .ring-one { width: 210px; height: 210px; }
  .ring-two { width: 170px; height: 170px; }
  .project-card { transform: none !important; }
  .reveal { transform: perspective(900px) translate3d(0, 32px, 0) rotateX(5deg) scale(.97); clip-path: inset(4% 2% round 22px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scroll-progress { display: none; }
  .code-window::after { animation: none; }
  .page-loader { transition: none; }
  .particle-canvas, .cursor-glow, .scene, .floating-card, .placeholder-icon { display: none; }
  .hero h1 .headline-word, .hero-description, .hero-actions, .tech-row, .status-pill,
  .reveal, .reveal-stagger > * {
    opacity: 1;
    transform: none;
    filter: none;
    clip-path: none;
    transition: none;
  }
}
