:root {
  --bg: #07080d;
  --bg-alt: #0d0f17;
  --text: #eef0f6;
  --text-muted: #9aa1b4;
  --blue: #4f7bff;
  --red: #ff4d6d;
  --gold: #ffb648;
  --border: #1c2030;
  --max-width: 900px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.65;
  overflow-x: hidden;
}

h1, h2, h3 {
  font-family: "Sora", "Inter", sans-serif;
}

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

a {
  color: var(--blue);
  text-decoration: none;
}

/* ---------- animated background ---------- */
.bg-blobs {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
}

.blob {
  position: absolute;
  width: 46vw;
  height: 46vw;
  max-width: 620px;
  max-height: 620px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.32;
  will-change: transform;
}

.blob-blue {
  background: radial-gradient(circle, var(--blue), transparent 70%);
  top: -12%;
  left: -10%;
  animation: float-a 22s ease-in-out infinite;
}

.blob-red {
  background: radial-gradient(circle, var(--red), transparent 70%);
  top: 30%;
  right: -14%;
  animation: float-b 26s ease-in-out infinite;
}

.blob-gold {
  background: radial-gradient(circle, var(--gold), transparent 70%);
  bottom: -16%;
  left: 20%;
  width: 34vw;
  height: 34vw;
  max-width: 460px;
  max-height: 460px;
  opacity: 0.22;
  animation: float-c 30s ease-in-out infinite;
}

@keyframes float-a {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(6vw, 8vh) scale(1.12); }
}

@keyframes float-b {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-7vw, -6vh) scale(1.08); }
}

@keyframes float-c {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(4vw, -5vh) scale(1.15); }
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

main, header, footer {
  position: relative;
  z-index: 2;
}

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  background: rgba(7, 8, 13, 0.7);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  position: relative;
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 0;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--text);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.logo {
  font-family: "Sora", sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
}

.logo .dot {
  color: var(--red);
}

nav {
  display: flex;
  gap: 28px;
}

nav a {
  position: relative;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 4px 0;
}

nav a span {
  position: relative;
}

nav a span::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--blue), var(--red));
  transition: width 0.25s ease;
}

nav a:hover {
  color: var(--text);
  text-decoration: none;
}

nav a:hover span::after {
  width: 100%;
}

nav a.active {
  color: var(--text);
}

nav a.active span::after {
  width: 100%;
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  nav {
    position: absolute;
    top: calc(100% + 1px);
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(7, 8, 13, 0.97);
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .site-header.nav-open nav {
    max-height: 320px;
  }

  nav a {
    padding: 16px 24px;
    width: 100%;
  }

  nav a span::after {
    display: none;
  }

  nav a.active,
  nav a:hover {
    background: rgba(79, 123, 255, 0.08);
  }
}

/* ---------- reveal-on-scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(.2,.7,.2,1), transform 0.7s cubic-bezier(.2,.7,.2,1);
}

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

/* ---------- hero ---------- */
.hero {
  padding: 120px 0 60px;
  text-align: center;
  position: relative;
}

.eyebrow {
  display: inline-block;
  color: var(--blue);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.85rem;
  margin-bottom: 18px;
  padding: 6px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(79, 123, 255, 0.06);
}

.hero h1 {
  font-size: clamp(2.8rem, 8vw, 4.6rem);
  font-weight: 800;
  margin: 0 0 8px;
  background: linear-gradient(100deg, #fff 20%, var(--blue) 55%, var(--red) 85%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  letter-spacing: -0.02em;
}

.role-rotator {
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  font-weight: 600;
  margin: 0 0 24px;
  min-height: 2.2em;
}

.role-prefix {
  color: var(--text-muted);
  font-weight: 500;
  margin-right: 8px;
}

.role-word {
  display: inline-block;
  color: var(--text);
  border-right: 2px solid var(--red);
  padding-right: 6px;
}

.hero-lead {
  color: var(--text-muted);
  font-size: 1.15rem;
  max-width: 600px;
  margin: 0 auto 36px;
}

/* ---------- hero photo ---------- */
.hero-photo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 32px;
}

.photo-frame {
  position: relative;
  width: 168px;
  height: 168px;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, var(--blue), var(--red));
  animation: photo-float 6s ease-in-out infinite;
}

.photo-frame img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 12%;
  border: 3px solid var(--bg);
}

@keyframes photo-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* ---------- page hero (subpages) ---------- */
.page-hero {
  padding: 100px 0 56px;
  text-align: center;
}

.page-hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.2rem);
  font-weight: 800;
  margin: 0 0 14px;
  background: linear-gradient(100deg, #fff 20%, var(--blue) 55%, var(--red) 85%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  letter-spacing: -0.02em;
}

.page-hero .hero-lead {
  margin: 0 auto;
}

/* ---------- about photo layout ---------- */
.about-layout {
  display: grid;
  grid-template-columns: 380px 1fr;
  gap: 44px;
  align-items: stretch;
}

.about-photo {
  position: relative;
  border-radius: 18px;
  padding: 6px;
  background: linear-gradient(135deg, var(--blue), var(--red));
}

.about-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  border-radius: 14px;
  border: 3px solid var(--bg);
}

@media (max-width: 920px) {
  .about-layout {
    grid-template-columns: 1fr;
    gap: 28px;
    align-items: start;
  }
  .about-photo {
    max-width: min(340px, 80vw);
    margin: 0 auto;
  }
  .about-photo img {
    height: auto;
    aspect-ratio: 4 / 5;
  }
}

/* ---------- explore grid (home teasers) ---------- */
.explore-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.explore-card {
  position: relative;
  display: block;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 26px;
  overflow: hidden;
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.explore-card:hover {
  border-color: transparent;
  transform: translateY(-6px);
  text-decoration: none;
}

.explore-card .venture-glow {
  border-radius: 16px;
}

.explore-card h3 {
  margin: 0 0 8px;
  color: var(--text);
  font-size: 1.15rem;
}

.explore-card p {
  margin: 0 0 16px;
  font-size: 0.95rem;
}

.explore-link {
  color: var(--blue);
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.explore-card:hover .arrow {
  transform: translateX(4px);
}

.cta-row {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  position: relative;
  display: inline-block;
  padding: 13px 28px;
  border-radius: 10px;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  overflow: hidden;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-3px);
}

.btn-primary {
  background: linear-gradient(120deg, var(--blue), var(--red));
  color: #fff;
  box-shadow: 0 8px 24px -8px rgba(79, 123, 255, 0.5);
}

.btn-primary:hover {
  box-shadow: 0 12px 32px -6px rgba(255, 77, 109, 0.5);
}

.btn-secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--blue);
}

.scroll-cue {
  margin: 56px auto 0;
  width: 26px;
  height: 42px;
  border: 2px solid var(--border);
  border-radius: 14px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}

.scroll-cue span {
  width: 4px;
  height: 8px;
  border-radius: 2px;
  background: var(--blue);
  animation: scroll-cue 1.6s ease infinite;
}

@keyframes scroll-cue {
  0% { transform: translateY(0); opacity: 1; }
  70% { transform: translateY(12px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* ---------- stats ---------- */
.stats-bar {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 40px 0;
  background: rgba(255, 255, 255, 0.015);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  text-align: center;
}

.stat-number {
  display: block;
  font-family: "Sora", sans-serif;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  background: linear-gradient(100deg, var(--blue), var(--red));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.stat-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 6px;
}

/* ---------- sections ---------- */
.section {
  padding: 88px 0;
}

.section-alt {
  background: var(--bg-alt);
}

.heading-tag {
  color: var(--red);
  font-family: "Sora", sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  margin-right: 12px;
  opacity: 0.8;
}

.section h2 {
  font-size: 1.9rem;
  font-weight: 700;
  margin-bottom: 28px;
  display: flex;
  align-items: center;
}

.section p {
  color: var(--text-muted);
}

.highlight {
  color: var(--text) !important;
  font-weight: 600;
  font-size: 1.15rem;
  border-left: 3px solid var(--blue);
  padding-left: 16px;
}

/* ---------- skills ---------- */
.skills-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}

.skills-grid li {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 20px 20px 52px;
  font-weight: 500;
  transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.skills-grid li:hover {
  border-color: var(--blue);
  transform: translateY(-4px);
  background: rgba(79, 123, 255, 0.05);
}

.skill-index {
  position: absolute;
  left: 18px;
  top: 20px;
  font-family: "Sora", sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--red);
  opacity: 0.7;
}

/* ---------- ventures ---------- */
.ventures-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.venture-card {
  position: relative;
  display: block;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px;
  overflow: hidden;
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.venture-card:hover {
  border-color: transparent;
  transform: translateY(-6px);
  text-decoration: none;
}

.venture-glow {
  position: absolute;
  inset: -1px;
  border-radius: 16px;
  padding: 1px;
  background: linear-gradient(120deg, var(--blue), var(--red));
  opacity: 0;
  transition: opacity 0.25s ease;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.venture-card:hover .venture-glow {
  opacity: 1;
}

.venture-num {
  display: inline-block;
  font-family: "Sora", sans-serif;
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--red);
  opacity: 0.7;
  margin-bottom: 12px;
}

.venture-card h3 {
  margin: 0 0 10px;
  color: var(--text);
}

.venture-card p {
  margin: 0 0 18px;
}

.venture-link {
  color: var(--blue);
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.venture-card:hover .arrow {
  transform: translateX(4px);
}

.arrow {
  display: inline-block;
  transition: transform 0.2s ease;
}

/* ---------- contact ---------- */
.contact-list {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.contact-list li a {
  display: inline-block;
  padding: 11px 20px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  font-weight: 500;
  transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.contact-list li a:hover {
  border-color: transparent;
  background: linear-gradient(120deg, var(--blue), var(--red));
  color: #fff;
  transform: translateY(-3px);
  text-decoration: none;
}

.contact-list li a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.social-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* ---------- footer ---------- */
.site-footer {
  padding: 40px 0 32px;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-social {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 0 0 22px;
  padding: 0;
}

.footer-social li a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.footer-social li a:hover {
  border-color: transparent;
  background: linear-gradient(120deg, var(--blue), var(--red));
  color: #fff;
  transform: translateY(-2px);
  text-decoration: none;
}

.footer-social .social-icon {
  width: 15px;
  height: 15px;
}

@media (max-width: 640px) {
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .photo-frame {
    width: 136px;
    height: 136px;
  }

  .hero {
    padding: 48px 0 40px;
  }

  .page-hero {
    padding: 40px 0 40px;
  }

  .section {
    padding: 56px 0;
  }
}

/* ---------- mobile card carousels ---------- */
@media (max-width: 700px) {
  .skills-grid,
  .ventures-grid,
  .explore-grid {
    display: flex;
    flex-wrap: nowrap;
    grid-template-columns: none;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin: 0 -24px;
    padding: 4px 24px 12px;
  }

  .skills-grid::-webkit-scrollbar,
  .ventures-grid::-webkit-scrollbar,
  .explore-grid::-webkit-scrollbar {
    display: none;
  }

  .skills-grid li,
  .ventures-grid .venture-card,
  .explore-grid .explore-card {
    flex: 0 0 78%;
    scroll-snap-align: start;
  }
}

/* ---------- lighter background blur on mobile (keep the float animation) ---------- */
@media (max-width: 768px) {
  .blob {
    filter: blur(50px);
  }
}
