:root {
  --bg: #0b0d12;
  --bg-alt: #12151c;
  --card: #161a23;
  --border: #242a37;
  --text: #eef0f4;
  --text-dim: #9aa2b1;
  --accent: #6ee7b7;
  --accent-2: #7c9bff;
  --gradient: linear-gradient(135deg, #6ee7b7, #7c9bff);
  --radius: 14px;
  --maxw: 1100px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  line-height: 1.15;
  margin: 0;
}

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

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
}

/* CUSTOM CURSOR */
.cursor-dot, .cursor-ring {
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  border-radius: 50%;
  z-index: 9999;
  display: none;
  transform: translate(-50%, -50%);
}
.cursor-dot { width: 6px; height: 6px; background: var(--accent); }
.cursor-ring {
  width: 34px; height: 34px;
  border: 1px solid var(--accent-2);
  transition: width 0.25s, height 0.25s, border-color 0.25s, background 0.25s;
}
.cursor-ring.cursor-hover {
  width: 54px; height: 54px;
  background: rgba(110,231,183,0.08);
  border-color: var(--accent);
}
@media (hover: hover) and (pointer: fine) {
  .cursor-dot, .cursor-ring { display: block; }
}

/* AMBIENT BACKGROUND */
.ambient {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.28;
}
.blob-1 { width: 460px; height: 460px; background: var(--accent); top: -140px; left: -120px; animation: float-blob 20s ease-in-out infinite; }
.blob-2 { width: 420px; height: 420px; background: var(--accent-2); bottom: -160px; right: -120px; animation: float-blob 24s ease-in-out infinite reverse; }
.blob-3 { width: 320px; height: 320px; background: var(--accent-2); top: 45%; left: 55%; animation: float-blob 28s ease-in-out infinite; }

@keyframes float-blob {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(50px, -40px) scale(1.1); }
  66% { transform: translate(-40px, 30px) scale(0.92); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* HEADER */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  background: rgba(11,13,18,0.55);
  border-bottom: 1px solid transparent;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
}
.site-header.scrolled {
  background: rgba(11,13,18,0.85);
  border-bottom-color: var(--border);
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.logo {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1.3rem;
}
.logo span { color: var(--accent); }

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 32px;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font-size: 0.95rem;
  color: var(--text-dim);
  transition: color 0.2s;
  position: relative;
}
.nav-links li:not(:last-child) a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -4px;
  width: 0; height: 1px;
  background: var(--accent);
  transition: width 0.25s;
}
.nav-links li:not(:last-child) a:hover::after { width: 100%; }
.nav-links a:hover { color: var(--text); }

.nav-cta {
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--gradient);
  color: #0b0d12 !important;
  font-weight: 600;
  display: inline-block;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

/* HERO */
.hero {
  padding: 110px 24px 60px;
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

.eyebrow {
  color: var(--accent);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(2rem, 4.2vw, 3.3rem);
  font-weight: 700;
  margin-bottom: 24px;
}

.highlight {
  background: linear-gradient(90deg, var(--accent), var(--accent-2), var(--accent));
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shimmer 5s linear infinite;
}
@keyframes shimmer { to { background-position: -200% center; } }

.hero-sub {
  max-width: 560px;
  color: var(--text-dim);
  font-size: 1.05rem;
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.15s ease-out, box-shadow 0.2s, background 0.2s, border-color 0.2s;
  will-change: transform;
}

.btn-primary {
  background: var(--gradient);
  color: #0b0d12;
}
.btn-primary:hover { box-shadow: 0 8px 24px rgba(110,231,183,0.25); }

.btn-ghost {
  border: 1px solid var(--border);
  color: var(--text);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  border-top: 1px solid var(--border);
  padding-top: 36px;
}

.stat { display: flex; flex-direction: column; gap: 6px; }

.stat-num {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
}

.stat-label {
  color: var(--text-dim);
  font-size: 0.82rem;
}

/* HERO VISUAL */
.hero-visual { position: relative; display: flex; justify-content: center; }
.hero-visual-inner {
  position: relative;
  width: min(360px, 90%);
  aspect-ratio: 1 / 1;
  transition: transform 0.2s ease-out;
}

.hero-image-ring {
  position: absolute;
  inset: -14px;
  border-radius: 42% 58% 55% 45% / 45% 40% 60% 55%;
  background: conic-gradient(from 0deg, var(--accent), var(--accent-2), var(--accent));
  animation: ring-rotate 10s linear infinite;
  opacity: 0.65;
}
@keyframes ring-rotate { to { transform: rotate(360deg); } }

.hero-image-frame {
  position: absolute;
  inset: 0;
  border-radius: 42% 58% 55% 45% / 45% 40% 60% 55%;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--border);
}

.floating-badge {
  position: absolute;
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(22,26,35,0.75);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}
.badge-1 { top: 6%; left: -14%; animation: floaty 6s ease-in-out infinite; }
.badge-2 { bottom: 12%; right: -12%; animation: floaty 7s ease-in-out infinite 1s; }
.badge-3 { bottom: -4%; left: 8%; animation: floaty 8s ease-in-out infinite 2s; }
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 8px;
  transform: translateX(-50%);
  width: 26px;
  height: 42px;
  border: 2px solid var(--border);
  border-radius: 20px;
  display: none;
}
.scroll-cue span {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 4px;
  height: 8px;
  background: var(--accent);
  border-radius: 4px;
  transform: translateX(-50%);
  animation: scroll-cue 1.6s ease-in-out infinite;
}
@keyframes scroll-cue {
  0% { opacity: 1; top: 8px; }
  70% { opacity: 0; top: 20px; }
  100% { opacity: 0; top: 8px; }
}

/* IMAGE FRAME (generic placeholder) */
.img-frame {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(110,231,183,0.06), rgba(124,155,255,0.06));
  border: 1px solid var(--border);
}
.frame-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.6s ease;
}
.frame-hint {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--text-dim);
  font-size: 0.72rem;
  text-align: center;
  padding: 16px;
  transition: opacity 0.4s ease;
}
.frame-hint svg { opacity: 0.7; }
.img-frame.loaded .frame-img { opacity: 1; }
.img-frame.loaded .frame-hint { opacity: 0; pointer-events: none; }

/* LOGO BADGE (small circular placeholder) */
.logo-badge {
  position: relative;
  width: 76px;
  height: 76px;
  min-width: 76px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.logo-badge .frame-img { border-radius: 50%; }
.logo-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  color: var(--text-dim);
  font-size: 1.05rem;
  transition: opacity 0.4s ease;
}
.logo-badge.loaded .frame-img { opacity: 1; }
.logo-badge.loaded .logo-fallback { opacity: 0; }

.logo-badge--tl {
  width: 44px;
  height: 44px;
  min-width: 44px;
  position: absolute;
  left: -60px;
  top: 0;
  font-size: 0.85rem;
}
.logo-badge--tl .logo-fallback { font-size: 0.75rem; }

/* MARQUEE */
.marquee-section {
  position: relative;
  z-index: 1;
  padding: 40px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}
.marquee-label {
  color: var(--text-dim);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 24px;
  text-align: center;
}
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, black 8%, black 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, black 8%, black 92%, transparent);
}
.marquee-track {
  display: flex;
  gap: 28px;
  width: max-content;
  animation: marquee 34s linear infinite;
}
.marquee-track--reverse {
  animation-name: marquee-reverse;
  animation-duration: 40s;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes marquee-reverse { from { transform: translateX(-50%); } to { transform: translateX(0); } }

.poster-frame {
  width: 190px;
  height: 240px;
  border-radius: var(--radius);
  flex: none;
}
.poster-frame .frame-hint { font-size: 0.68rem; }

/* SECTIONS */
.section {
  padding: 90px 24px;
  position: relative;
  z-index: 1;
}

.section-tag {
  color: var(--accent-2);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  font-weight: 700;
  margin-bottom: 48px;
  max-width: 700px;
}

/* ABOUT */
.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 56px;
  align-items: start;
}

.about-collage {
  position: relative;
  height: 420px;
}
.collage-1 {
  position: absolute;
  top: 0; left: 0;
  width: 72%;
  height: 78%;
  border-radius: var(--radius);
  transition: transform 0.2s ease-out;
}
.collage-2 {
  position: absolute;
  bottom: 0; right: 0;
  width: 62%;
  height: 55%;
  border-radius: var(--radius);
  border: 4px solid var(--bg);
  box-shadow: 0 20px 50px rgba(0,0,0,0.4);
  transition: transform 0.2s ease-out;
}

.about-text {
  color: var(--text-dim);
  font-size: 1.05rem;
  margin-bottom: 20px;
}
.about-text strong { color: var(--text); }
.about-text a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }

.education-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  margin-top: 12px;
}
.education-card h3 { font-size: 1.1rem; margin-bottom: 18px; }
.education-card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 18px; }
.education-card li { display: flex; flex-direction: column; gap: 4px; }
.edu-degree { font-weight: 600; }
.edu-school { color: var(--text-dim); font-size: 0.9rem; }

/* CASE STUDY */
.case-study {
  background: var(--bg-alt);
  border-radius: 24px;
  border: 1px solid var(--border);
  overflow: hidden;
}
.case-glow {
  position: absolute;
  top: -80px;
  right: -80px;
  width: 320px;
  height: 320px;
  background: var(--gradient);
  filter: blur(120px);
  opacity: 0.2;
  pointer-events: none;
}
.case-desc { color: var(--text-dim); max-width: 620px; margin-bottom: 40px; font-size: 1.05rem; position: relative; }

.case-stats {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
  margin-bottom: 32px;
  position: relative;
}
.case-stat { display: flex; flex-direction: column; gap: 4px; }
.case-num {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2.6rem;
  font-weight: 700;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.case-stat span:last-child { color: var(--text-dim); font-size: 0.9rem; }

.case-tags { display: flex; flex-wrap: wrap; gap: 10px; position: relative; }

/* TIMELINE */
.timeline {
  position: relative;
  padding-left: 32px;
  display: flex;
  flex-direction: column;
  gap: 44px;
  margin-bottom: 56px;
}
.timeline-line {
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 1px;
  background: var(--border);
}
.timeline-progress {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 0%;
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
  transition: height 0.1s linear;
}

.timeline-item { position: relative; }

.timeline-dot {
  position: absolute;
  left: -37.5px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(110,231,183,0.15);
  z-index: 1;
}

.timeline-content { margin-left: 56px; }
.timeline-content h3 { font-size: 1.2rem; margin-bottom: 4px; }
.timeline-org { color: var(--accent-2); font-weight: 600; font-size: 0.95rem; margin: 0 0 8px; }
.timeline-desc { color: var(--text-dim); margin: 0; max-width: 600px; }

.freelance h3 { font-size: 1.1rem; margin-bottom: 16px; }

.chip-row { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  background: var(--card);
  border: 1px solid var(--border);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.88rem;
  color: var(--text-dim);
  transition: border-color 0.2s, color 0.2s;
}
.chip:hover { border-color: var(--accent); color: var(--text); }

/* SKILLS */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.skill-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform 0.2s ease-out, border-color 0.2s;
}
.skill-card:hover { border-color: var(--accent); }
.skill-card h3 { font-size: 1.05rem; margin-bottom: 18px; }

/* WORK */
.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.work-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s ease-out, border-color 0.2s;
}
.work-card:hover { border-color: var(--accent); }
.work-frame { aspect-ratio: 16 / 10; }
.work-body { padding: 22px; }
.work-tag {
  display: inline-block;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
}
.work-card h3 { font-size: 1.1rem; margin-bottom: 10px; }
.work-card p { color: var(--text-dim); font-size: 0.92rem; margin: 0; }

/* CONTACT */
.contact-section { text-align: center; }
.contact-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 64px 32px;
  position: relative;
  overflow: hidden;
}
.contact-card::before {
  content: '';
  position: absolute;
  inset: -2px;
  background: var(--gradient);
  opacity: 0.15;
  filter: blur(60px);
  z-index: -1;
}
.contact-sub { color: var(--text-dim); max-width: 500px; margin: 0 auto 40px; }
.contact-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* FOOTER */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
  position: relative;
  z-index: 1;
}
.footer-inner { text-align: center; color: var(--text-dim); font-size: 0.85rem; }

/* REVEAL ANIMATION */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* RESPONSIVE */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; }
  .hero-visual { order: -1; margin-bottom: 20px; }
  .hero-visual-inner { width: min(280px, 70%); margin: 0 auto; }
  .about-grid { grid-template-columns: 1fr; }
  .about-collage { height: 320px; margin-bottom: 12px; }
  .skills-grid { grid-template-columns: 1fr; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: flex-start;
    padding: 24px;
    gap: 20px;
    display: none;
  }
  .nav-links.open { display: flex; }
  .hero { padding-top: 90px; }
  .case-stats { gap: 32px; }
  .badge-1, .badge-2, .badge-3 { font-size: 0.72rem; padding: 8px 12px; }
  .badge-1 { left: -6%; }
  .badge-2 { right: -6%; }
}