:root {
  --bg: #02030a;
  --bg-elevated: #050712;
  --bg-soft: #0b0d18;

  --border-subtle: #242637;
  --border-strong: #3b425a;

  --accent: #c084fc;
  --accent-2: #60a5fa;
  --accent-soft: rgba(192, 132, 252, 0.16);

  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --text-soft: #6b7280;

  --danger: #f87171;

  --radius-lg: 18px;
  --radius-md: 999px;

  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.7);

  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Inter", sans-serif;

  /* parallax defaults */
  --parallax-x: 0;
  --parallax-y: 0;
}

/* RESET */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: radial-gradient(circle at top, #020308 0, #020617 55%, #000 100%);
  color: var(--text-main);
  font-family: var(--font-sans);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  animation: pageFadeIn 0.5s ease-out;
}

@keyframes pageFadeIn {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* global glow */
body::before,
body::after {
  content: "";
  position: fixed;
  pointer-events: none;
  inset: auto;
  width: 420px;
  height: 420px;
  filter: blur(80px);
  opacity: 0.5;
  z-index: -2;
}

body::before {
  top: -120px;
  right: 6%;
  background:
    radial-gradient(circle, rgba(129, 140, 248, 0.5), transparent 60%);
  animation: bodyGlowDrift 24s ease-in-out infinite alternate;
}

body::after {
  bottom: -160px;
  left: -40px;
  background:
    radial-gradient(circle, rgba(236, 72, 153, 0.4), transparent 60%);
  animation: bodyGlowDrift 26s ease-in-out infinite alternate-reverse;
}

@keyframes bodyGlowDrift {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(18px, -24px, 0);
  }
}

/* subtle star field */
html::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -3;
  background-image:
    radial-gradient(circle at 10% 20%, rgba(255, 255, 255, 0.18) 0, transparent 40%),
    radial-gradient(circle at 80% 10%, rgba(255, 255, 255, 0.12) 0, transparent 45%),
    radial-gradient(circle at 40% 80%, rgba(255, 255, 255, 0.1) 0, transparent 40%);
  opacity: 0.16;
  mix-blend-mode: screen;
}

/* HEADER */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 5vw;
  backdrop-filter: blur(24px);
  background: linear-gradient(
    to bottom,
    rgba(3, 7, 18, 0.98),
    rgba(3, 7, 18, 0.95),
    rgba(3, 7, 18, 0.82),
    transparent
  );
  border-bottom: 1px solid rgba(15, 23, 42, 0.95);
  box-shadow:
    0 10px 28px rgba(15, 23, 42, 0.9),
    0 0 0 1px rgba(15, 23, 42, 0.95);
}

.logo {
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  font-size: 0.78rem;
  padding: 0.55rem 1.6rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(55, 65, 81, 0.95);
  background: radial-gradient(circle at top left, #020617, #020617 55%, #000);
  color: #e5e7eb;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 1),
    0 18px 52px rgba(0, 0, 0, 0.95);
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.9),
    0 0 18px rgba(15, 23, 42, 0.9);
}

/* metallic sheen */
.logo::after {
  content: "";
  position: absolute;
  inset: -1px;
  background: linear-gradient(
    120deg,
    transparent 0%,
    rgba(255, 255, 255, 0.33) 32%,
    transparent 60%
  );
  mix-blend-mode: screen;
  opacity: 0;
  transform: translateX(-60%);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

.logo:hover::after {
  opacity: 1;
  transform: translateX(30%);
}

.nav {
  display: flex;
  gap: 1.3rem;
  align-items: center;
}

.nav a {
  position: relative;
  font-size: 0.9rem;
  text-decoration: none;
  color: var(--text-muted);
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  transition:
    color 0.18s ease,
    background 0.18s ease,
    transform 0.12s ease;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0.9rem;
  right: 0.9rem;
  bottom: 0.05rem;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(to right, #4f46e5, #ec4899);
  transform: scaleX(0);
  transform-origin: center;
  opacity: 0;
  transition: transform 0.18s ease-out, opacity 0.18s ease-out;
}

.nav a:hover {
  color: var(--text-main);
  background: rgba(15, 23, 42, 0.9);
  transform: translateY(-1px);
}

.nav a:hover::after {
  transform: scaleX(1);
  opacity: 1;
}

.nav a.active {
  color: var(--text-main);
  background: rgba(15, 23, 42, 0.95);
}

.nav a.active::after {
  transform: scaleX(1);
  opacity: 1;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  padding: 0.35rem;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px 0;
  background: var(--text-main);
  border-radius: 999px;
}

/* HERO PANEL */
.hero {
  position: relative;
  overflow: hidden;
  padding: 4.2rem 5vw 3.6rem;
  max-width: 1120px;
  margin: 2.8rem auto 3rem;
  border-radius: 32px;
  background: radial-gradient(circle at top left, #050815, #020617 60%, #000);
  border: 1px solid rgba(15, 23, 42, 0.96);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 1),
    0 32px 90px rgba(0, 0, 0, 0.98);
}

.hero-layout {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(0, 1.1fr);
  gap: 2.7rem;
  align-items: center;
  z-index: 1;
}

@media (max-width: 900px) {
  .hero-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

.hero-content {
  max-width: 680px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.25em;
  font-size: 0.7rem;
  color: var(--text-soft);
  margin-bottom: 0.9rem;
}

.hero h1 {
  font-size: clamp(2.4rem, 4vw, 3.2rem);
  line-height: 1.07;
  margin: 0 0 1.1rem;
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.95),
    0 0 28px rgba(15, 23, 42, 0.95);
}

.hero-subtitle {
  max-width: 540px;
  color: var(--text-muted);
  font-size: 0.98rem;
  line-height: 1.7;
  margin-bottom: 1.7rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.85rem;
  margin: 0 0 0.9rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.75);
  background: radial-gradient(circle at top left, #020617, #050816);
  color: var(--text-soft);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.2rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition:
    background 0.18s ease,
    color 0.18s ease,
    transform 0.12s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.btn.primary {
  background: radial-gradient(circle at top left, #4f46e5, #7c3aed);
  border-color: rgba(129, 140, 248, 0.7);
  box-shadow:
    0 10px 25px rgba(55, 48, 163, 0.7),
    0 0 0 1px rgba(15, 23, 42, 1);
  color: white;
}

.btn.primary:hover {
  transform: translateY(-1px);
  box-shadow:
    0 18px 35px rgba(55, 48, 163, 0.8),
    0 0 0 1px rgba(148, 163, 184, 0.9);
}

.btn.ghost {
  background: rgba(15, 23, 42, 0.9);
  border-color: rgba(55, 65, 81, 0.95);
  color: var(--text-main);
}

.btn.ghost:hover {
  background: rgba(15, 23, 42, 1);
  transform: translateY(-1px);
}

.btn.small {
  padding: 0.45rem 0.95rem;
  font-size: 0.82rem;
}

/* HERO META */
.hero-meta {
  margin-top: 2.3rem;
  padding: 1.1rem 1.4rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: radial-gradient(circle at top left, #020617, #050816);
  box-shadow:
    0 0 0 1px rgba(3, 7, 18, 1),
    0 18px 45px rgba(0, 0, 0, 0.9);
  max-width: 680px;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.7rem;
}

.pill {
  padding: 0.2rem 0.7rem;
  font-size: 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(75, 85, 99, 0.9);
  color: var(--text-soft);
  background: rgba(15, 23, 42, 0.98);
}

.hero-note {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* hero ambient layers */
.hero-ambient {
  position: absolute;
  inset: -50px;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  will-change: transform;
  transform: translate3d(
    calc(var(--parallax-x) * 24px),
    calc(var(--parallax-y) * 24px),
    0
  );
  transition: transform 0.18s ease-out;
}

/* liquid ink */
.hero-ink-layer {
  position: absolute;
  inset: -30%;
  background:
    radial-gradient(circle at 5% 10%, rgba(15, 23, 42, 0.95) 0, transparent 55%),
    radial-gradient(circle at 85% 15%, rgba(76, 81, 191, 0.95) 0, transparent 60%),
    radial-gradient(circle at 20% 85%, rgba(15, 23, 42, 1) 0, transparent 55%),
    radial-gradient(circle at 80% 80%, rgba(59, 130, 246, 0.9) 0, transparent 60%);
  filter: blur(18px);
  opacity: 0.9;
  animation: heroInkDrift 18s ease-in-out infinite alternate;
}

/* particle glow */
.hero-particle-layer {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 15% 25%, rgba(229, 231, 235, 0.5) 0, transparent 55%),
    radial-gradient(circle at 75% 30%, rgba(209, 213, 219, 0.32) 0, transparent 60%),
    radial-gradient(circle at 45% 80%, rgba(209, 213, 219, 0.35) 0, transparent 60%);
  opacity: 0.8;
  mix-blend-mode: screen;
  animation: heroParticleDrift 22s linear infinite alternate;
}

@keyframes heroInkDrift {
  0% {
    transform: translate3d(-18px, 10px, 0) scale(1.02);
  }
  50% {
    transform: translate3d(22px, -18px, 0) scale(1.08);
  }
  100% {
    transform: translate3d(-14px, 18px, 0) scale(1.05);
  }
}

@keyframes heroParticleDrift {
  0% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(-26px, 18px, 0);
  }
  100% {
    transform: translate3d(20px, -22px, 0);
  }
}

/* HERO VISUAL */
.hero-visual {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9rem;
  justify-self: center;
  will-change: transform;
  transform: translate3d(
    calc(var(--parallax-x) * -18px),
    calc(var(--parallax-y) * -18px),
    0
  );
  transition: transform 0.2s ease-out;
}

.hero-visual-orbit {
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  background:
    radial-gradient(circle at 30% 0%, rgba(148, 163, 184, 0.18), transparent 60%);
  filter: blur(1px);
  opacity: 0.9;
  animation: heroOrbitPulse 10s ease-in-out infinite alternate;
}

.hero-avatar {
  position: relative;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(226, 232, 240, 0.95);
  box-shadow:
    0 18px 45px rgba(0, 0, 0, 0.9),
    0 0 0 1px rgba(15, 23, 42, 1);
  backdrop-filter: blur(12px);
  animation: heroAvatarFloat 9s ease-in-out infinite alternate;
  z-index: 1;
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-visual-caption {
  font-size: 0.85rem;
  color: #ffffff;
  text-align: center;
  max-width: 240px;
  opacity: 0.95;
  mix-blend-mode: normal;
}

@keyframes heroAvatarFloat {
  0% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(0, -6px, 0);
  }
  100% {
    transform: translate3d(0, -2px, 0);
  }
}

@keyframes heroOrbitPulse {
  0% {
    transform: scale(1);
    opacity: 0.75;
  }
  100% {
    transform: scale(1.06);
    opacity: 1;
  }
}

@media (max-width: 900px) {
  .hero {
    margin-top: 1.5rem;
    padding-top: 3.3rem;
  }

  .hero-visual-orbit {
    width: 220px;
    height: 220px;
  }
  .hero-avatar {
    width: 150px;
    height: 150px;
  }
}

/* SECTIONS */
.section {
  padding: 3.5rem 5vw;
  max-width: 1120px;
  margin: 0 auto;
}

.section-header {
  max-width: 680px;
  margin-bottom: 2rem;
}

.section-header h2 {
  font-size: 1.35rem;
  margin: 0 0 0.4rem;
  position: relative;
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.9),
    0 0 18px rgba(15, 23, 42, 0.95);
}

.section-header h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.4rem;
  width: 40px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(to right, #4f46e5, #ec4899);
  opacity: 0.95;
}

.section-header p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.section-alt {
  background: radial-gradient(circle at top left, #020617, #020617 60%, #000);
  border-radius: 26px;
  border: 1px solid rgba(31, 41, 55, 0.98);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 1),
    0 26px 70px rgba(0, 0, 0, 0.95);
  margin-top: 2.5rem;
  margin-bottom: 2.5rem;
  backdrop-filter: blur(16px);
}

/* GRID */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.4rem;
}

.card {
  --spotlight-x: 50%;
  --spotlight-y: 0%;

  border-radius: var(--radius-lg);
  background: radial-gradient(circle at top left, #020617, #020617 60%, #030712);
  border: 1px solid rgba(31, 41, 55, 0.98);
  padding: 1.4rem 1.4rem 1.2rem;
  box-shadow:
    0 0 0 1px rgba(3, 7, 18, 1),
    0 22px 55px rgba(0, 0, 0, 0.95);
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  position: relative;
  overflow: hidden;
  transform: translateY(0);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease;
  z-index: 0;
}

/* soft glow underlay */
.card::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: radial-gradient(
    circle at top,
    rgba(192, 132, 252, 0.24),
    transparent 60%
  );
  opacity: 0;
  mix-blend-mode: soft-light;
  transition: opacity 0.22s ease;
  pointer-events: none;
  z-index: 0;
}

/* hover spotlight */
.card::after {
  content: "";
  position: absolute;
  inset: -1px;
  pointer-events: none;
  background:
    radial-gradient(
      circle at var(--spotlight-x) var(--spotlight-y),
      rgba(250, 250, 255, 0.14),
      transparent 55%
    );
  opacity: 0;
  mix-blend-mode: screen;
  transition: opacity 0.22s ease-out;
  z-index: 0;
}

.card:hover {
  transform: translateY(-5px) translateZ(0);
  box-shadow:
    0 0 0 1px rgba(148, 163, 184, 0.6),
    0 32px 80px rgba(0, 0, 0, 0.98);
  border-color: rgba(148, 163, 184, 0.9);
  background: radial-gradient(circle at top left, #020617, #020617 55%, #020617);
}

.card:hover::before,
.card:hover::after {
  opacity: 1;
}

.card-actions {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
  position: relative;
  z-index: 1;
}

.card-actions a {
  pointer-events: auto;
  cursor: pointer;
}

.card h3 {
  margin: 0;
  font-size: 1rem;
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.9),
    0 0 14px rgba(15, 23, 42, 0.9);
}

.card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

.tag-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0;
  margin: 0.2rem 0 0.6rem;
}

.tag-list li {
  font-size: 0.7rem;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  border: 1px solid rgba(75, 85, 99, 0.9);
  color: var(--text-soft);
  background: rgba(3, 7, 18, 0.9);
}

.text-link {
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--text-muted);
}

.text-link:hover {
  color: var(--text-main);
}

.disabled {
  opacity: 0.45;
  cursor: default;
  pointer-events: none;
}

/* SPLIT SECTION */
.section-split {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.4fr);
  gap: 2.5rem;
  align-items: flex-start;
}

.section-body p {
  margin: 0 0 0.8rem;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.8;
}

/* CONTACT */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.1fr);
  gap: 2rem;
}

.contact-list,
.focus-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.contact-list li,
.focus-list li {
  margin-bottom: 0.6rem;
}

.contact-list span {
  display: inline-block;
  width: 3.9rem;
  color: var(--text-soft);
}

.contact-list a {
  color: var(--text-main);
  text-decoration: none;
}

.contact-list a:hover {
  text-decoration: underline;
}

/* contact page card wrapper */
.contact-card {
  padding: 1.8rem 1.8rem 1.6rem;
}

/* FOOTER */
.site-footer {
  padding: 1.8rem 5vw 2.2rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-soft);
  border-top: 1px solid rgba(15, 23, 42, 0.95);
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.9);
}

/* REVEAL ANIMATIONS (sections/cards) */
.reveal {
  opacity: 0;
  transform: translateY(18px) scale(0.98);
  transition:
    opacity 0.6s ease-out,
    transform 0.6s ease-out;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.reveal.delay-1.in-view {
  transition-delay: 0.08s;
}

.reveal.delay-2.in-view {
  transition-delay: 0.16s;
}

.reveal.delay-3.in-view {
  transition-delay: 0.24s;
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .nav {
    position: fixed;
    inset: 3.2rem 1.1rem auto 1.1rem;
    padding: 0.9rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    background: rgba(15, 23, 42, 0.98);
    border-radius: 18px;
    border: 1px solid rgba(55, 65, 81, 0.95);
    transform: translateY(-24px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.16s ease, transform 0.16s ease;
  }

  .nav.open {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
  }

  .nav-toggle {
    display: inline-flex;
  }

  .section-split,
  .contact-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact-card {
    padding: 1.4rem 1.2rem 1.3rem;
  }
}
