:root {
  --pink: #ff9ecb;
  --lavender: #c9a8ff;
  --gold: #ffd58a;
  --bg: #0a0e27;
  --bg-alt: #12173f;
  --text: #f5f1ff;
  --text-dim: #a8a4c9;
  --card-bg: rgba(255,255,255,0.05);
  --card-border: rgba(255,255,255,0.10);
  --gradient: linear-gradient(135deg, var(--pink), var(--lavender));
  --header-h: 72px;
  --container-w: 1080px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

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

a { color: inherit; text-decoration: none; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* STARFIELD BACKGROUND */
.stars-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: var(--bg);
  overflow: hidden;
  pointer-events: none;
}
.star {
  position: absolute;
  background: #fff;
  border-radius: 50%;
  animation: twinkle var(--dur, 3s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}
@keyframes twinkle {
  0%, 100% { opacity: var(--min-op, .25); transform: scale(1); }
  50% { opacity: 1; transform: scale(1.3); }
}
.shooting-star {
  position: absolute;
  width: 2px;
  height: 2px;
  background: linear-gradient(90deg, #fff, transparent);
  border-radius: 50%;
  box-shadow: 0 0 6px 1px #fff;
  opacity: 0;
  animation: shoot 8s linear infinite;
}
@keyframes shoot {
  0% { opacity: 0; transform: translate(0,0) rotate(-30deg) scaleX(1); }
  2% { opacity: 1; }
  8% { opacity: 0; transform: translate(280px, 160px) rotate(-30deg) scaleX(40); }
  100% { opacity: 0; }
}
.constellation {
  position: absolute;
  opacity: .35;
}

/* cursor glow */
.cursor-glow {
  position: fixed;
  width: 420px; height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,158,203,0.12), transparent 70%);
  pointer-events: none;
  transform: translate(-50%, -50%);
  z-index: 1;
  transition: opacity .3s;
  left: 0; top: 0;
}

/* HEADER */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  z-index: 100;
  transition: background .3s ease, box-shadow .3s ease, backdrop-filter .3s ease;
}
.site-header.scrolled {
  background: rgba(10,14,39,0.75);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(255,255,255,0.06);
}

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

.logo {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: .5px;
}
.logo-dot { color: var(--gold); }

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-link {
  position: relative;
  padding: 8px 14px;
  font-size: .95rem;
  color: var(--text-dim);
  transition: color .25s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 14px; right: 14px; bottom: 2px;
  height: 2px;
  background: var(--gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s ease;
}
.nav-link:hover,
.nav-link.active { color: var(--text); }
.nav-link.active::after,
.nav-link:hover::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 101;
}
.nav-toggle span {
  width: 24px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform .3s ease, opacity .3s ease;
}

/* SECTIONS */
.section {
  position: relative;
  padding: 120px 0 100px;
}

.section-title {
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  margin-bottom: 16px;
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: "";
  position: absolute;
  left: 0; bottom: -12px;
  width: 56px; height: 4px;
  border-radius: 2px;
  background: var(--gradient);
}

/* reveal-on-scroll base state */
.reveal {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity .7s cubic-bezier(.2,.7,.3,1), transform .7s cubic-bezier(.2,.7,.3,1);
  transition-delay: var(--delay, 0s);
}
.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* HERO */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--header-h);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  align-items: center;
  gap: 40px;
}

.hero-kicker {
  color: var(--gold);
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: .85rem;
  margin-bottom: 12px;
}

.hero-name {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 800;
  line-height: 1.1;
  min-height: 1.15em;
}
.typed-name {
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-dot {
  color: var(--gold);
  -webkit-text-fill-color: var(--gold);
  opacity: 0;
  transition: opacity .4s ease;
}
.hero-dot.show { opacity: 1; }
.typewriter-cursor {
  display: inline-block;
  width: 3px;
  height: 0.85em;
  margin-left: 3px;
  background: var(--gold);
  vertical-align: middle;
  animation: blinkCursor .8s steps(2) infinite;
}
.typewriter-cursor.hide { display: none; }
@keyframes blinkCursor {
  50% { opacity: 0; }
}

.hero-role {
  margin-top: 14px;
  font-size: 1.1rem;
  color: var(--text-dim);
}

.hero-desc {
  margin-top: 18px;
  max-width: 480px;
  color: var(--text-dim);
}

.hero-builtby {
  margin-top: 14px;
  max-width: 480px;
  color: var(--text-dim);
  font-size: 0.85rem;
  font-style: italic;
  opacity: 0.8;
  border-left: 2px solid var(--pink);
  padding-left: 12px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.btn {
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
  display: inline-block;
}
.btn-primary {
  background: var(--gradient);
  color: #241236;
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 30px -8px rgba(255,158,203,0.5);
}
.btn-ghost {
  border: 1px solid var(--card-border);
  color: var(--text);
}
.btn-ghost:hover {
  transform: translateY(-3px);
  background: rgba(255,255,255,0.06);
}

.social-row {
  display: flex;
  gap: 14px;
  margin-top: 36px;
}
.social-icon {
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--card-border);
  transition: transform .3s ease, background .3s ease, border-color .3s ease;
}
.social-icon svg {
  width: 18px; height: 18px;
  fill: var(--text-dim);
  transition: fill .3s ease;
}
.social-icon:hover {
  transform: translateY(-4px);
  background: var(--gradient);
  border-color: transparent;
}
.social-icon:hover svg { fill: #241236; }

.hero-image {
  position: relative;
  width: 440px;
  max-width: 100%;
  height: 440px;
  margin: 0 auto;
}

/* MOON — full moon peeking from behind the side of the photo, fully visible */
.moon-glow {
  position: absolute;
  top: 0;
  right: 0;
  width: 210px; height: 210px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,213,138,0.55), transparent 70%);
  filter: blur(6px);
  animation: moonPulse 6s ease-in-out infinite;
  z-index: 0;
}
@keyframes moonPulse {
  0%, 100% { opacity: .7; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}
.moon {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 170px; height: 170px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fffdf3, #ffe9b8 55%, #f4c97a 100%);
  box-shadow: 0 0 40px 10px rgba(255,213,138,0.45);
  z-index: 0;
  overflow: hidden;
}
.moon-crater {
  position: absolute;
  border-radius: 50%;
  background: rgba(200,160,90,0.35);
}
.moon-crater.c1 { width: 30px; height: 30px; top: 28px; left: 36px; }
.moon-crater.c2 { width: 20px; height: 20px; top: 86px; left: 96px; }
.moon-crater.c3 { width: 14px; height: 14px; top: 55px; left: 118px; }

.photo-cutout {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 310px; height: 310px;
  z-index: 1;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-alt);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 4px solid var(--bg);
  box-shadow:
    0 0 0 4px rgba(255,255,255,0.08),
    0 0 35px 8px rgba(255,158,203,0.45),
    0 0 60px 18px rgba(201,168,255,0.25),
    0 30px 60px -20px rgba(0,0,0,0.6);
  animation: photoGlowPulse 4.5s ease-in-out infinite;
}
@keyframes photoGlowPulse {
  0%, 100% {
    box-shadow:
      0 0 0 4px rgba(255,255,255,0.08),
      0 0 35px 8px rgba(255,158,203,0.45),
      0 0 60px 18px rgba(201,168,255,0.25),
      0 30px 60px -20px rgba(0,0,0,0.6);
  }
  50% {
    box-shadow:
      0 0 0 4px rgba(255,255,255,0.1),
      0 0 48px 14px rgba(255,158,203,0.6),
      0 0 80px 24px rgba(201,168,255,0.35),
      0 30px 60px -20px rgba(0,0,0,0.6);
  }
}
.photo-cutout::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  padding: 4px;
  background: var(--gradient);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  z-index: 2;
  pointer-events: none;
}
.photo-cutout img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.avatar-fallback {
  display: none;
  width: 100%; height: 100%;
  align-items: center; justify-content: center;
  font-size: 4rem;
  font-weight: 800;
  background: var(--gradient);
  color: rgba(36,18,54,0.85);
}

/* HOBBIES */
.hobby-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 48px;
}
.hobby-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 32px 24px;
  text-align: center;
  transition: transform .35s cubic-bezier(.2,.8,.3,1), border-color .3s ease, background .3s ease;
}
.hobby-card:hover {
  transform: perspective(600px) rotateX(6deg) translateY(-8px);
  border-color: rgba(255,158,203,0.4);
  background: rgba(255,255,255,0.06);
}
.hobby-icon {
  font-size: 2.6rem;
  margin-bottom: 14px;
  transition: transform .3s ease;
}
.hobby-card:hover .hobby-icon { transform: scale(1.2) rotate(-6deg); }
.hobby-card h3 { margin-bottom: 8px; }
.hobby-card p { color: var(--text-dim); font-size: .9rem; }

/* EXPERIENCE / TIMELINE */
.timeline {
  position: relative;
  padding-left: 32px;
  margin-top: 48px;
}
.timeline-line {
  position: absolute;
  left: 6px; top: 0;
  width: 2px;
  height: 100%;
  background: rgba(255,255,255,0.08);
}
.timeline-line::before {
  content: "";
  position: absolute;
  left: 0; top: 0;
  width: 100%;
  height: var(--fill, 0%);
  background: var(--gradient);
  transition: height .2s linear;
}

.timeline-item {
  position: relative;
  padding: 0 0 44px 32px;
}
.timeline-item:last-child { padding-bottom: 0; }

.timeline-dot {
  position: absolute;
  left: -32px; top: 6px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--gold);
  box-shadow: 0 0 0 4px rgba(255,213,138,0.12);
}

.timeline-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 24px 28px;
  transition: transform .3s ease, border-color .3s ease;
}
.timeline-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255,158,203,0.4);
}
.timeline-date {
  font-size: .8rem;
  color: var(--gold);
  font-weight: 600;
  letter-spacing: .5px;
}
.timeline-card h3 { margin-top: 6px; font-size: 1.2rem; }
.timeline-company { color: var(--text-dim); font-size: .9rem; margin: 4px 0 10px; }
.timeline-card p:last-child { color: var(--text-dim); font-size: .95rem; }

/* GALLERY */
.gallery-sub {
  color: var(--text-dim);
  margin-bottom: 32px;
  max-width: 560px;
}
.gallery-filters {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}
.filter-btn {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  color: var(--text-dim);
  padding: 10px 22px;
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .25s ease;
}
.filter-btn:hover { color: var(--text); border-color: rgba(255,158,203,0.4); }
.filter-btn.active {
  background: var(--gradient);
  color: #241236;
  border-color: transparent;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.gallery-item {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: pointer;
  border: 1px solid var(--card-border);
  transition: transform .4s cubic-bezier(.2,.8,.3,1), opacity .3s ease;
}
.gallery-item.hidden { display: none; }
.gallery-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .5s ease;
}
.gallery-item:hover { transform: translateY(-6px); }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 14px 16px;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text);
  background: linear-gradient(to top, rgba(10,14,39,0.9), transparent);
}

/* LIGHTBOX */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(10,14,39,0.92);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
  padding: 24px;
}
.lightbox.active { opacity: 1; visibility: visible; }
.lightbox img {
  max-width: min(90vw, 700px);
  max-height: 75vh;
  border-radius: 14px;
  box-shadow: 0 30px 60px -10px rgba(0,0,0,0.6);
}
.lightbox-caption { color: var(--text-dim); font-size: .95rem; }
.lightbox-close {
  position: absolute;
  top: 24px; right: 32px;
  background: none;
  border: none;
  color: var(--text);
  font-size: 2.2rem;
  cursor: pointer;
  line-height: 1;
}

/* SCROLL CUE */
.scroll-cue {
  position: absolute;
  bottom: 32px; left: 50%;
  transform: translateX(-50%);
  width: 26px; height: 42px;
  border: 2px solid var(--card-border);
  border-radius: 20px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
  z-index: 2;
}
.scroll-cue span {
  width: 4px; height: 8px;
  border-radius: 2px;
  background: var(--gradient);
  animation: scrollCue 1.6s ease infinite;
}
@keyframes scrollCue {
  0% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(14px); }
}

/* FOOTER */
.site-footer {
  position: relative;
  z-index: 2;
  padding: 56px 0 28px;
  border-top: 1px solid var(--card-border);
  background: var(--bg-alt);
}
.footer-grid {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
}
.footer-tag { color: var(--text-dim); margin-top: 8px; font-size: .9rem; }
.footer-copy {
  text-align: center;
  color: var(--text-dim);
  font-size: .8rem;
  margin-top: 40px;
  position: relative;
  z-index: 2;
}

/* RESPONSIVE */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-desc { margin: 18px auto 0; }
  .hero-actions { justify-content: center; }
  .social-row { justify-content: center; }
  .hero-image { order: -1; margin-bottom: 20px; width: 320px; height: 320px; }
  .moon { width: 120px; height: 120px; }
  .moon-glow { width: 150px; height: 150px; }
  .photo-cutout { width: 230px; height: 230px; }
}

@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: fixed;
    top: 0; right: 0;
    height: 100vh;
    width: min(280px, 80vw);
    background: rgba(10,14,39,0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: 40px;
    gap: 12px;
    transform: translateX(100%);
    transition: transform .35s ease;
    z-index: 101;
  }
  .nav-links.open { transform: translateX(0); }
  .cursor-glow { display: none; }
}
