/* ============================================================
   Nishant Shah — premium dark / interactive portfolio
   ============================================================ */

:root {
  --bg: #08090d;
  --bg-2: #0d0f15;
  --panel: rgba(255, 255, 255, 0.025);
  --panel-2: rgba(255, 255, 255, 0.04);
  --line: rgba(255, 255, 255, 0.09);
  --line-soft: rgba(255, 255, 255, 0.06);
  --text: #edeef2;
  --muted: #9aa0ad;
  --faint: #636978;
  --a1: #8b7bff;   /* indigo */
  --a2: #2fd4c4;   /* teal */
  --disp: "Space Grotesk", system-ui, sans-serif;
  --sans: "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", monospace;
  --maxw: 1200px;
  --pad: clamp(20px, 5.5vw, 70px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 17px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -2;
  background:
    radial-gradient(800px circle at 12% -5%, rgba(139,123,255,0.16), transparent 50%),
    radial-gradient(700px circle at 95% 12%, rgba(47,212,196,0.10), transparent 45%),
    radial-gradient(900px circle at 50% 115%, rgba(139,123,255,0.10), transparent 50%);
}
.noise {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  opacity: .035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: inherit; text-decoration: none; }
em { font-style: normal; }

.grad {
  background: linear-gradient(100deg, var(--a2), var(--a1));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------------- NAV ---------------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px var(--pad);
  transition: padding .35s, background .35s, border-color .35s, backdrop-filter .35s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  padding-top: 14px; padding-bottom: 14px;
  background: rgba(8,9,13,0.72);
  backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid var(--line);
}
.nav__logo {
  font-family: var(--disp); font-weight: 600; font-size: 1.05rem; letter-spacing: .2px;
}
.nav__dot { color: var(--a2); }
.nav__links { display: flex; align-items: center; gap: 30px; }
.nav__links a { font-size: .9rem; color: var(--muted); transition: color .2s; position: relative; }
.nav__links a:not(.nav__cta)::after {
  content: ""; position: absolute; left: 0; bottom: -5px; height: 1px; width: 0;
  background: linear-gradient(90deg, var(--a2), var(--a1)); transition: width .25s;
}
.nav__links a:hover { color: var(--text); }
.nav__links a:not(.nav__cta):hover::after { width: 100%; }
.nav__cta {
  color: var(--text) !important; padding: 8px 18px; border: 1px solid var(--line);
  border-radius: 999px; background: var(--panel-2); transition: border-color .2s, transform .2s;
}
.nav__cta:hover { border-color: var(--a2); transform: translateY(-1px); }
.nav__toggle { display: none; flex-direction: column; gap: 6px; background: none; border: 0; cursor: pointer; padding: 4px; }
.nav__toggle span { width: 24px; height: 1.6px; background: var(--text); transition: .3s; }

/* ---------------- BUTTONS ---------------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; font-weight: 600; font-size: .96rem;
  font-family: var(--sans); cursor: pointer; transition: transform .22s, box-shadow .3s, background .3s, border-color .3s;
  border: 1px solid transparent;
}
.btn--solid {
  background: linear-gradient(100deg, var(--a2), var(--a1)); color: #07090d;
  box-shadow: 0 10px 36px rgba(47,212,196,0.18);
}
.btn--solid:hover { transform: translateY(-3px); box-shadow: 0 16px 46px rgba(139,123,255,0.32); }
.btn--line { border-color: var(--line); color: var(--text); background: var(--panel); }
.btn--line:hover { border-color: var(--a1); transform: translateY(-3px); }

/* ---------------- HERO ---------------- */
.hero {
  position: relative; min-height: 100vh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 140px var(--pad) 90px; max-width: var(--maxw); margin: 0 auto;
}
.hero__net { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: .9; }
.hero__inner { max-width: 880px; }
.hero__eyebrow {
  font-family: var(--mono); font-size: .82rem; letter-spacing: 1px; text-transform: uppercase;
  color: var(--a2); margin-bottom: 28px;
}
.hero__title {
  font-family: var(--disp); font-weight: 700;
  font-size: clamp(2.7rem, 8.5vw, 6.2rem); line-height: 0.98; letter-spacing: -2px;
}
.hero__title span { display: block; }
.hero__sub {
  margin: 32px 0 40px; font-size: clamp(1rem, 1.7vw, 1.2rem);
  color: var(--muted); max-width: 56ch;
}
.hero__sub strong, .hero__title .grad { font-weight: 700; }
.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; }
.hero__scroll {
  position: absolute; bottom: 34px; left: var(--pad);
  display: flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: .72rem; letter-spacing: 2px; text-transform: uppercase; color: var(--faint);
}
.hero__scroll span {
  width: 24px; height: 1px; background: var(--faint); position: relative; overflow: hidden;
}
.hero__scroll span::after {
  content: ""; position: absolute; inset: 0; width: 8px; background: var(--a2);
  animation: scrollline 2s infinite;
}
@keyframes scrollline { 0% { transform: translateX(-8px); } 100% { transform: translateX(24px); } }

/* ---------------- MARQUEE ---------------- */
.marquee {
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  padding: 20px 0; overflow: hidden; background: var(--bg-2);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee__track { display: flex; align-items: center; gap: 34px; white-space: nowrap; width: max-content; animation: scroll-x 36s linear infinite; }
.marquee span { font-family: var(--disp); font-size: 1.5rem; font-weight: 500; color: var(--text); opacity: .85; }
.marquee i { color: var(--a2); font-size: 1rem; font-style: normal; }
@keyframes scroll-x { to { transform: translateX(-50%); } }

/* ---------------- SECTIONS ---------------- */
.section { max-width: var(--maxw); margin: 0 auto; padding: clamp(70px, 13vh, 140px) var(--pad); }
.section__label {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: .82rem; letter-spacing: 2px; text-transform: uppercase;
  color: var(--muted); margin-bottom: 56px;
}
.section__label span { color: var(--a2); }
.section__label.center { justify-content: center; }

/* ---------------- ABOUT ---------------- */
.about__grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(34px, 6vw, 90px); align-items: start; }
.about__statement {
  font-family: var(--disp); font-weight: 500; font-size: clamp(1.6rem, 3.3vw, 2.5rem);
  line-height: 1.22; letter-spacing: -0.8px;
}
.about__statement em { color: transparent; background: linear-gradient(100deg,var(--a2),var(--a1)); -webkit-background-clip: text; background-clip: text; }
.about__col p { color: var(--muted); margin-bottom: 20px; }
.about__col strong { color: var(--text); font-weight: 600; }
.about__meta { margin-top: 30px; border-top: 1px solid var(--line); }
.about__meta div {
  display: flex; gap: 18px; padding: 14px 0; border-bottom: 1px solid var(--line-soft); font-size: .94rem;
}
.about__meta span {
  font-family: var(--mono); font-size: .72rem; text-transform: uppercase; letter-spacing: 1px;
  color: var(--faint); min-width: 86px;
}

/* ---------------- PROJECT SCENES ---------------- */
.scene {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 5vw, 72px);
  align-items: center; margin-bottom: clamp(70px, 11vh, 130px);
}
.scene--reverse .scene__viz { order: 2; }
.scene__viz {
  position: relative; aspect-ratio: 4 / 3; border-radius: 20px;
  border: 1px solid var(--line); background: linear-gradient(160deg, var(--bg-2), #0a0c12);
  overflow: hidden; box-shadow: 0 30px 80px rgba(0,0,0,0.45);
}
.scene__viz::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 3;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.04);
  border-radius: 20px;
}
.viz { width: 100%; height: 100%; display: block; }
.viz__badges { position: absolute; left: 16px; bottom: 16px; display: flex; gap: 8px; flex-wrap: wrap; z-index: 4; }
.viz__badges span {
  font-family: var(--mono); font-size: .68rem; letter-spacing: .3px;
  padding: 5px 11px; border-radius: 999px; color: var(--text);
  background: rgba(8,9,13,0.6); border: 1px solid var(--line); backdrop-filter: blur(6px);
}

.scene__no { font-family: var(--mono); font-size: .82rem; color: var(--a2); letter-spacing: 2px; margin-bottom: 14px; }
.scene__text h3 { font-family: var(--disp); font-weight: 600; font-size: clamp(1.5rem, 2.8vw, 2.1rem); line-height: 1.12; letter-spacing: -0.6px; margin-bottom: 10px; }
.scene__kicker { color: var(--a1); font-size: .9rem; margin-bottom: 16px; }
.scene__text > p { color: var(--muted); margin-bottom: 20px; max-width: 52ch; }
.scene__tags { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.scene__tags li {
  font-family: var(--mono); font-size: .74rem; padding: 5px 12px;
  border: 1px solid var(--line); border-radius: 999px; color: var(--muted);
}
.scene__award { font-family: var(--mono); font-size: .78rem; color: var(--a2); margin-bottom: 18px; }
.scene__link {
  display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: .94rem;
  border-bottom: 1px solid var(--text); padding-bottom: 3px; transition: gap .25s, color .2s, border-color .2s;
}
.scene__link span { transition: transform .25s; }
.scene__link:hover { gap: 12px; color: var(--a2); border-color: var(--a2); }
.scene__link:hover span { transform: translate(2px,-2px); }

/* ---- Aqua dashboard viz ---- */
.dash { position: absolute; inset: 0; padding: 22px; display: flex; flex-direction: column; }
.dash__head { font-family: var(--mono); font-size: .76rem; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); display: flex; align-items: center; gap: 9px; margin-bottom: 18px; }
.dash__live { width: 8px; height: 8px; border-radius: 50%; background: var(--a2); box-shadow: 0 0 12px var(--a2); animation: pulse 1.8s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .3; } }
.dash__grid { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.metric { border: 1px solid var(--line); border-radius: 12px; padding: 14px; background: var(--panel); display: flex; flex-direction: column; justify-content: space-between; }
.metric__k { font-family: var(--mono); font-size: .66rem; text-transform: uppercase; letter-spacing: 1px; color: var(--faint); }
.metric__v { font-family: var(--disp); font-size: clamp(1.3rem, 3vw, 1.9rem); font-weight: 600; color: var(--text); }
.metric--tank { position: relative; overflow: hidden; }
.tank { position: relative; flex: 1; margin-top: 10px; border-radius: 8px; overflow: hidden; background: rgba(47,212,196,0.06); min-height: 38px; }
.tank__wave { position: absolute; left: 0; right: 0; bottom: 0; height: 60%; background: linear-gradient(180deg, rgba(47,212,196,0.5), rgba(47,212,196,0.15)); transition: height 1s ease; }
.tank__wave::before { content: ""; position: absolute; top: -6px; left: 0; right: 0; height: 8px; background: var(--a2); opacity: .5; border-radius: 50%; animation: bob 2.4s ease-in-out infinite; }
@keyframes bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(3px); } }
.dash__foot { margin-top: 14px; font-family: var(--mono); font-size: .72rem; color: var(--a2); }

/* ---- Chat viz ---- */
.chat { position: absolute; inset: 0; padding: 22px; display: flex; flex-direction: column; gap: 12px; }
.chat__head { font-family: var(--mono); font-size: .76rem; text-transform: uppercase; letter-spacing: 1px; color: var(--muted); margin-bottom: 4px; }
.bubble { max-width: 78%; padding: 11px 15px; border-radius: 14px; font-size: .9rem; line-height: 1.4; opacity: 0; transform: translateY(8px); animation: bubblein .5s forwards; }
.bubble--in { align-self: flex-start; background: var(--panel-2); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.bubble--out { align-self: flex-end; background: linear-gradient(100deg, rgba(47,212,196,0.18), rgba(139,123,255,0.18)); border: 1px solid var(--line); border-bottom-right-radius: 4px; }
.scene.in .bubble:nth-child(2) { animation-delay: .1s; }
.scene.in .bubble:nth-child(3) { animation-delay: .35s; }
.scene.in .bubble:nth-child(4) { animation-delay: .6s; }
.scene.in .bubble:nth-child(5) { animation-delay: .85s; }
@keyframes bubblein { to { opacity: 1; transform: none; } }

/* ---------------- INITIATIVES ---------------- */
.inits { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.init { border: 1px solid var(--line); border-radius: 16px; padding: 28px; background: var(--panel); transition: transform .3s, border-color .3s; }
.init:hover { transform: translateY(-5px); border-color: var(--a1); }
.init__no { font-family: var(--mono); font-size: .8rem; color: var(--a2); margin-bottom: 12px; }
.init h4 { font-family: var(--disp); font-weight: 600; font-size: 1.25rem; margin-bottom: 8px; }
.init p { color: var(--muted); font-size: .94rem; }
.init strong { color: var(--text); }

/* ---------------- EXPERIENCE ---------------- */
.exp { list-style: none; }
.exp__row { display: grid; grid-template-columns: 150px 1fr; gap: clamp(18px, 4vw, 50px); padding: 26px 0; border-top: 1px solid var(--line); transition: padding-left .3s; }
.exp__row:hover { padding-left: 10px; }
.exp__row:last-child { border-bottom: 1px solid var(--line); }
.exp__when { font-family: var(--mono); font-size: .8rem; letter-spacing: .5px; color: var(--a2); padding-top: 4px; }
.exp__what h3 { font-family: var(--disp); font-weight: 600; font-size: 1.3rem; margin-bottom: 6px; }
.exp__what p { color: var(--muted); font-size: .95rem; max-width: 62ch; }

/* ---------------- CONTACT ---------------- */
.contact { text-align: center; }
.contact__title { font-family: var(--disp); font-weight: 700; font-size: clamp(2.2rem, 6vw, 4.4rem); letter-spacing: -1.5px; line-height: 1.05; margin: 16px 0 18px; }
.contact__sub { color: var(--muted); max-width: 48ch; margin: 0 auto 34px; }
.contact__email {
  font-family: var(--disp); font-size: clamp(1.2rem, 3.4vw, 2rem); font-weight: 500;
  border-bottom: 1px solid var(--line); padding-bottom: 6px; transition: color .2s, border-color .2s;
}
.contact__email:hover { color: var(--a2); border-color: var(--a2); }
.contact__links { display: flex; gap: 26px; justify-content: center; margin-top: 40px; }
.contact__links a { font-family: var(--mono); font-size: .86rem; color: var(--muted); transition: color .2s; }
.contact__links a:hover { color: var(--text); }

/* ---------------- FOOTER ---------------- */
.footer {
  max-width: var(--maxw); margin: 0 auto; padding: 32px var(--pad) 44px;
  display: flex; justify-content: space-between; border-top: 1px solid var(--line);
  font-family: var(--mono); font-size: .76rem; letter-spacing: .5px; color: var(--faint);
}

/* ---------------- REVEAL ---------------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.hero__title .reveal:nth-child(2) { transition-delay: .08s; }
.hero__title .reveal:nth-child(3) { transition-delay: .16s; }

/* ---------------- RESPONSIVE ---------------- */
@media (max-width: 860px) {
  .about__grid { grid-template-columns: 1fr; }
  .scene { grid-template-columns: 1fr; gap: 26px; }
  .scene--reverse .scene__viz { order: 0; }
  .inits { grid-template-columns: 1fr; }
  .exp__row { grid-template-columns: 1fr; gap: 6px; }
  .nav__links {
    position: fixed; inset: 0 0 0 auto; width: min(72vw, 320px);
    flex-direction: column; justify-content: center; gap: 30px; padding: 0 40px;
    background: rgba(10,11,16,0.97); backdrop-filter: blur(18px);
    border-left: 1px solid var(--line); transform: translateX(100%); transition: transform .35s ease;
  }
  .nav__links.open { transform: translateX(0); }
  .nav__toggle { display: flex; z-index: 110; }
  .nav.menu-open .nav__toggle span:nth-child(1) { transform: translateY(3.8px) rotate(45deg); }
  .nav.menu-open .nav__toggle span:nth-child(2) { transform: translateY(-3.8px) rotate(-45deg); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .bubble { opacity: 1; transform: none; }
}
