/* sourovaskar.com — portfolio styles.
   Bold-modern direction: oversized type, hard-edged blocks, an amber/gold
   accent over deep charcoal. Dark-only by design — the WebGL hero is authored
   against a dark ground, so a light variant would need a second scene palette
   rather than a token swap. */

:root {
  --bg: #0a0a0c;
  --bg-2: #111114;
  --bg-3: #17171c;
  --ink: #f7f6f3;
  --ink-dim: #a9a69f;
  --ink-faint: #6e6b65;
  --line: rgba(255, 255, 255, .10);
  --line-strong: rgba(255, 255, 255, .22);

  /* Accent: amber/gold reads as trade and craft rather than neon tech. */
  --hot: #f5a524;
  --cool: #e8dcc8;
  --deep: #b8791a;

  --radius: 4px;   /* hard edges — the bold-modern look, not soft cards */
  --wrap: 1240px;

  /* Elevation: layered shadows read as real depth where a single flat
     shadow reads as a sticker. Warm-tinted to sit in the amber scheme. */
  --lift-1: 0 1px 2px rgba(0,0,0,.5), 0 4px 12px rgba(0,0,0,.35);
  --lift-2: 0 2px 4px rgba(0,0,0,.5), 0 12px 28px rgba(0,0,0,.45), 0 30px 60px rgba(0,0,0,.35);
  --lift-3: 0 4px 8px rgba(0,0,0,.55), 0 22px 48px rgba(0,0,0,.5), 0 56px 100px rgba(0,0,0,.42);
  --glow: 0 0 0 1px rgba(245,165,36,.28), 0 18px 50px -18px rgba(245,165,36,.42);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background:
    radial-gradient(120% 70% at 50% -10%, #14141a, transparent 60%),
    var(--bg);
  color: var(--ink);
  font: 400 17px/1.68 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; }

.wrap { width: min(var(--wrap), 90vw); margin-inline: auto; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--hot); color: #12100a; padding: .7rem 1.1rem; font-weight: 700;
}
.skip:focus { left: 0; }

/* ------------------------------------------------------------------- nav */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .9rem clamp(1rem, 4vw, 2.4rem);
  backdrop-filter: blur(14px);
  background: linear-gradient(to bottom, rgba(10,10,12,.86), rgba(10,10,12,.20));
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.nav.solid { border-bottom-color: var(--line); background: rgba(10,10,12,.94); }

.brand {
  display: flex; align-items: center; gap: .6rem; text-decoration: none;
  font-weight: 800; letter-spacing: -.02em; text-transform: uppercase; font-size: .95rem;
}
.brand-mark { color: var(--hot); font-size: 1rem; }
.nav-links { display: flex; gap: 1.8rem; }
.nav-links a {
  text-decoration: none; font-size: .78rem; color: var(--ink-dim);
  text-transform: uppercase; letter-spacing: .14em; font-weight: 600;
  position: relative; padding: .2rem 0; transition: color .2s;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: -3px; height: 2px; width: 0;
  background: var(--hot); transition: width .25s;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { width: 100%; }

.nav-cta {
  text-decoration: none; font-size: .78rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .12em;
  padding: .6rem 1.2rem; border-radius: var(--radius);
  background: var(--hot); color: #12100a;
  transition: background .25s, transform .25s;
}
.nav-cta:hover { background: var(--ink); transform: translateY(-1px); }

@media (max-width: 760px) { .nav-links { display: none; } }

/* ------------------------------------------------------------------ hero */
.hero { position: relative; min-height: 100svh; display: grid; align-items: center; overflow: hidden; }

.stage { position: absolute; inset: 0; }
.stage canvas { width: 100%; height: 100%; display: block; }

/* Fallback ground shown until (or unless) the WebGL scene reports ready, so a
   machine without WebGL still gets an intentional-looking hero. */
.stage::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(50% 44% at 62% 46%, rgba(245,165,36,.24), transparent 70%),
    radial-gradient(40% 36% at 40% 62%, rgba(184,121,26,.20), transparent 72%);
  transition: opacity .9s ease;
}
.webgl-ready .stage::before { opacity: .45; }

/* Vignette keeps hero text readable over whatever the scene is doing. */
.hero::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(100deg, var(--bg) 8%, rgba(10,10,12,.74) 46%, rgba(10,10,12,.42) 100%),
    linear-gradient(to bottom, transparent 62%, var(--bg) 98%);
}

.hero-inner {
  position: relative; z-index: 2;
  width: min(var(--wrap), 90vw); margin-inline: auto; padding-top: 4rem;
  display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

.eyebrow {
  text-transform: uppercase; letter-spacing: .2em; font-size: .72rem; font-weight: 700;
  color: var(--hot); margin: 0 0 1.4rem;
  display: flex; align-items: center; gap: .8rem;
}
.eyebrow::before { content: ""; width: 34px; height: 2px; background: var(--hot); flex: none; }

h1 {
  margin: 0; font-weight: 800; letter-spacing: -.055em; line-height: .82;
  font-size: clamp(3.4rem, 11.5vw, 8.4rem); text-transform: uppercase;
  transform-style: preserve-3d;
}
/* The two lines sit at different depths, so the title itself has dimension. */
h1 .line { display: block; }
h1 .line:first-child { transform: translateZ(0); }
h1 .grad {
  color: var(--hot);
  text-shadow: 0 1px 0 rgba(0,0,0,.4), 0 14px 40px rgba(245,165,36,.22);
}
h1 .line { display: block; }
h1 .grad { color: var(--hot); }

.lede {
  max-width: 44ch; color: var(--ink-dim); margin: 1.8rem 0 0;
  font-size: clamp(1rem, 1.5vw, 1.1rem); border-left: 2px solid var(--line-strong); padding-left: 1.1rem;
}

.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2.4rem; }

/* Venture index in the hero — the numbered list from the bold-modern layout. */
.hero-index {
  display: grid; gap: 0;
  background: linear-gradient(165deg, rgba(26,26,33,.78), rgba(10,10,12,.72));
  backdrop-filter: blur(14px) saturate(120%);
  border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--lift-3), inset 0 1px 0 rgba(255,255,255,.06);
  transform: perspective(1200px) rotateY(-7deg) rotateX(2deg);
  transform-style: preserve-3d;
  transition: transform .6s cubic-bezier(.2,.7,.3,1);
}
.hero-index:hover { transform: perspective(1200px) rotateY(-2deg) rotateX(0deg); }
.hero-index a {
  display: flex; align-items: baseline; gap: 1rem; text-decoration: none;
  padding: 1.05rem 1.1rem; border-bottom: 1px solid var(--line);
  transition: background .25s, padding-left .25s;
}
.hero-index a:last-child { border-bottom: 0; }
.hero-index a:hover { background: rgba(245,165,36,.10); padding-left: 1.5rem; }
.hero-index .n {
  font-size: .72rem; font-weight: 700; color: var(--hot); letter-spacing: .1em; flex: none;
}
.hero-index .t { font-weight: 650; letter-spacing: -.01em; }
.hero-index .k {
  margin-left: auto; font-size: .68rem; color: var(--ink-dim); text-align: right;
  text-transform: uppercase; letter-spacing: .1em; flex: none;
}

@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-index { display: none; }  /* the cards below already carry this */
}

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  text-decoration: none; font-weight: 700; font-size: .82rem;
  text-transform: uppercase; letter-spacing: .1em;
  padding: .95rem 1.7rem; border-radius: var(--radius);
  transition: transform .25s, background .25s, border-color .25s, color .25s;
}
.btn-primary {
  background: linear-gradient(180deg, #ffb739, var(--hot));
  color: #12100a; box-shadow: var(--lift-2), inset 0 1px 0 rgba(255,255,255,.4);
}
.btn-primary:hover {
  background: linear-gradient(180deg, #ffc862, #f0a01f);
  transform: translateY(-3px); box-shadow: var(--lift-3), 0 0 30px -6px rgba(245,165,36,.55);
}
.btn-ghost { border: 1px solid var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--hot); color: var(--hot); transform: translateY(-2px); }

.scroll-hint {
  position: absolute; left: 50%; bottom: 1.7rem; translate: -50% 0; z-index: 2;
  width: 22px; height: 36px; border: 1px solid var(--line-strong); border-radius: 12px;
}
.scroll-hint span {
  position: absolute; left: 50%; top: 8px; translate: -50% 0;
  width: 3px; height: 7px; border-radius: 2px; background: var(--hot);
  animation: wheel 1.9s ease-in-out infinite;
}
@keyframes wheel { 0%,100% { opacity: 0; transform: translateY(0); } 40% { opacity: 1; } 70% { opacity: 0; transform: translateY(11px); } }

.noscript-note { position: absolute; inset: auto 0 2rem 0; text-align: center; color: var(--ink-dim); }

/* --------------------------------------------------------------- sections */
.section {
  padding: clamp(5.5rem, 12vw, 10rem) 0; position: relative;
  perspective: 1600px; perspective-origin: 50% 40%;
}

/* Depth wash: a soft radial that sits behind each section's content and drifts
   with scroll (see parallax() in app.js), so sections read as layered planes
   rather than flat bands of colour. */
.section::before {
  content: ""; position: absolute; inset: -20% 0 -20% 0; pointer-events: none; z-index: 0;
  background: radial-gradient(60% 42% at var(--px, 50%) var(--py, 42%), rgba(245,165,36,.055), transparent 68%);
  transition: opacity .6s;
}
.section > * { position: relative; z-index: 1; }
.section.alt { background: var(--bg-2); border-block: 1px solid var(--line); }

.kicker {
  text-transform: uppercase; letter-spacing: .18em; font-size: .72rem; font-weight: 700;
  color: var(--hot); margin: 0 0 .9rem;
  display: flex; align-items: center; gap: .8rem;
}
.kicker::before { content: ""; width: 28px; height: 2px; background: var(--hot); flex: none; }

h2 {
  margin: 0 0 3rem; font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800; letter-spacing: -.045em; line-height: 1.0; text-transform: uppercase;
  max-width: 18ch;
  text-shadow: 0 2px 0 rgba(0,0,0,.35);
}

/* ---------------------------------------------------------------- cards */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }

.card { perspective: 1100px; }
.card-face {
  position: relative; height: 100%;
  padding: 2.4rem 2rem 2rem;
  background: linear-gradient(168deg, #141419, var(--bg) 62%);
  transform-style: preserve-3d;
  transition: transform .4s cubic-bezier(.2,.7,.3,1),
              background .4s, box-shadow .4s;
  will-change: transform;
}
/* Inner content floats above the card plane, so the tilt has parallax within
   the card itself rather than moving as one rigid sheet. */
.card-face > * { transform: translateZ(22px); transform-style: preserve-3d; position: relative; z-index: 1; }
.card-face h3 { transform: translateZ(42px); }
.card-face .tag { transform: translateZ(34px); }
/* Sheen follows the pointer via --mx/--my set in app.js. */
.card-face::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(240px circle at var(--mx, 50%) var(--my, 0%), rgba(245,165,36,.13), transparent 62%);
  opacity: 0; transition: opacity .35s;
}
/* Numbered counter — set per card via --i in the markup. */
.card-face::after {
  content: counter(venture, decimal-leading-zero);
  position: absolute; right: 1.5rem; bottom: 1.2rem;
  font-size: 3.4rem; font-weight: 800; letter-spacing: -.05em; line-height: 1;
  color: transparent; -webkit-text-stroke: 1px rgba(255,255,255,.10);
  transform: translateZ(12px); transform-origin: 100% 100%;
  transition: transform .4s, -webkit-text-stroke-color .4s;
  pointer-events: none; z-index: 0;
}
.card:hover .card-face::after { -webkit-text-stroke-color: rgba(245,165,36,.55); }
.grid { counter-reset: venture; }
.card { counter-increment: venture; }
.card:hover .card-face {
  background: linear-gradient(168deg, #1b1b22, #0e0e12 62%);
  box-shadow: var(--lift-3), inset 0 1px 0 rgba(255,255,255,.07);
}
.card:hover .card-face::before { opacity: 1; }
.card:hover .card-face::after { transform: translateZ(30px) scale(1.06); }

.tag {
  display: inline-block; font-size: .66rem; letter-spacing: .14em; text-transform: uppercase;
  font-weight: 700; color: var(--hot);
  padding: 0 0 .5rem; margin-bottom: .9rem; border-bottom: 1px solid rgba(245,165,36,.34);
}
.card h3 { margin: 0 0 .7rem; font-size: 1.5rem; letter-spacing: -.03em; text-transform: uppercase; font-weight: 800; }
.card p { margin: 0 0 1.3rem; color: var(--ink-dim); font-size: .93rem; }

.chips { list-style: none; display: grid; gap: .45rem; padding: 0; margin: 0 0 1.4rem; }
.chips li {
  font-size: .78rem; color: var(--ink-dim); padding-left: 1rem; position: relative;
}
.chips li::before {
  content: ""; position: absolute; left: 0; top: .62em;
  width: 5px; height: 5px; background: var(--hot);
}
.card-link {
  text-decoration: none; font-size: .76rem; font-weight: 700; color: var(--hot);
  text-transform: uppercase; letter-spacing: .1em;
}
.card-link:hover { color: var(--ink); }

/* ------------------------------------------------------------- timeline */
.timeline { display: grid; gap: 0; counter-reset: step; }
.tl-item {
  display: grid; grid-template-columns: 9rem 1fr; gap: clamp(1rem, 4vw, 3.4rem);
  padding: 2.4rem 0 2.4rem 0; border-top: 1px solid var(--line); position: relative;
  transition: background .4s, padding-left .4s;
}
.tl-item:hover { background: linear-gradient(90deg, rgba(245,165,36,.05), transparent 60%); }
/* Node on the rail: a small lit marker that brightens as you reach the step. */
.tl-item::after {
  content: ""; position: absolute; left: 0; top: -4px;
  width: 7px; height: 7px; background: var(--bg-2);
  border: 1px solid var(--line-strong); border-radius: 50%;
  transition: background .4s, border-color .4s, box-shadow .4s;
}
.tl-item:hover::after {
  background: var(--hot); border-color: var(--hot);
  box-shadow: 0 0 0 4px rgba(245,165,36,.16), 0 0 18px rgba(245,165,36,.6);
}
.timeline { position: relative; padding-left: 0; }
.tl-item:last-child { border-bottom: 1px solid var(--line); }
.tl-phase {
  font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .14em;
  color: var(--hot); padding-top: .3rem;
}
.tl-body h3 { margin: 0 0 .5rem; font-size: 1.35rem; letter-spacing: -.025em; font-weight: 750; }
.tl-body p { margin: 0; color: var(--ink-dim); font-size: .94rem; max-width: 62ch; }
@media (max-width: 700px) {
  .tl-item { grid-template-columns: 1fr; gap: .6rem; }
}

/* ---------------------------------------------------------------- about */
.about { display: grid; grid-template-columns: 1.3fr .7fr; gap: clamp(2rem, 6vw, 4.5rem); align-items: center; }
.about p { color: var(--ink-dim); }
.facts { display: grid; gap: 0; margin: 2.4rem 0 0; }
.facts div { display: flex; gap: 1rem; border-top: 1px solid var(--line); padding: .9rem 0; }
.facts div:last-child { border-bottom: 1px solid var(--line); }
.facts dt { min-width: 7rem; color: var(--ink-faint); font-size: .72rem; text-transform: uppercase; letter-spacing: .14em; padding-top: .15rem; }
.facts dd { margin: 0; font-weight: 650; }

.about-3d {
  display: grid; place-items: center; min-height: 340px;
  perspective: 1000px; perspective-origin: 50% 45%;
}
/* Ground glow so the object sits in space rather than floating on nothing. */
.about-3d::after {
  content: ""; position: absolute; width: 260px; height: 60px;
  translate: 0 130px; border-radius: 50%;
  background: radial-gradient(50% 50%, rgba(245,165,36,.16), transparent 70%);
  filter: blur(12px);
}
.cube {
  position: relative; width: 160px; height: 160px;
  transform-style: preserve-3d; animation: spin 22s linear infinite;
}
@media (prefers-reduced-motion: reduce) { .cube { animation-duration: 90s; } }
.cube .f {
  position: absolute; inset: 0;
  border: 1px solid rgba(245,165,36,.5);
  background:
    linear-gradient(150deg, rgba(245,165,36,.22), rgba(184,121,26,.06) 60%, transparent);
  box-shadow:
    inset 0 0 50px rgba(245,165,36,.16),
    inset 0 1px 0 rgba(255,255,255,.16);
  backdrop-filter: blur(2px);
}
/* Per-face shading: opposing faces get different weight so the solid reads as
   lit from one side instead of glowing uniformly. */
.cube .tp { background: linear-gradient(150deg, rgba(245,165,36,.34), rgba(184,121,26,.10)); }
.cube .bt { background: linear-gradient(150deg, rgba(184,121,26,.10), rgba(10,10,12,.5)); }
.cube .lf, .cube .bk { background: linear-gradient(150deg, rgba(184,121,26,.12), rgba(10,10,12,.34)); }
.cube .fr { transform: translateZ(80px); }
.cube .bk { transform: rotateY(180deg) translateZ(80px); }
.cube .lf { transform: rotateY(-90deg) translateZ(80px); }
.cube .rt { transform: rotateY(90deg) translateZ(80px); }
.cube .tp { transform: rotateX(90deg) translateZ(80px); }
.cube .bt { transform: rotateX(-90deg) translateZ(80px); }
@keyframes spin { to { transform: rotateX(360deg) rotateY(720deg); } }

@media (max-width: 860px) { .about { grid-template-columns: 1fr; } .about-3d { order: -1; } }

/* ---------------------------------------------------------------- stack */
.stack { display: flex; flex-wrap: wrap; gap: 1px; background: var(--line); border: 1px solid var(--line); }
.stack span {
  background: var(--bg); padding: .95rem 1.3rem;
  font-size: .82rem; color: var(--ink-dim); flex: 1 1 auto; text-align: center;
  text-transform: uppercase; letter-spacing: .06em; font-weight: 600;
  transition: color .25s, background .25s;
}
.stack span {
  transition: color .3s, background .3s, transform .3s, box-shadow .3s;
}
.stack span:hover {
  color: #12100a; background: var(--hot);
  transform: translateY(-3px) scale(1.02); box-shadow: var(--lift-2);
  position: relative; z-index: 2;
}

/* -------------------------------------------------------------- contact */
.contact { text-align: center; }
.contact p { color: var(--ink-dim); max-width: 54ch; margin-inline: auto; }
.contact h2 { max-width: none; margin-inline: auto; }
.contact .kicker { justify-content: center; }
.contact-actions { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; margin-top: 2.4rem; }

/* Contact detail rows — email, phone, socials. */
.contact-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1px; background: var(--line); border: 1px solid var(--line);
  margin-top: 3rem; text-align: left;
}
.contact-grid a, .contact-grid div {
  background: var(--bg); padding: 1.4rem 1.4rem; text-decoration: none;
  display: grid; gap: .35rem; transition: background .25s;
}
.contact-grid a { position: relative; transition: background .3s, transform .3s, box-shadow .3s; }
.contact-grid a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 0;
  background: var(--hot); transition: width .35s;
}
.contact-grid a:hover {
  background: var(--bg-3); transform: translateY(-3px); box-shadow: var(--lift-2);
  z-index: 2;
}
.contact-grid a:hover::after { width: 100%; }
.contact-grid dt, .contact-grid .lbl {
  font-size: .68rem; text-transform: uppercase; letter-spacing: .14em; color: var(--ink-faint); font-weight: 700;
}
.contact-grid .val { font-weight: 650; font-size: .95rem; word-break: break-word; }
.contact-grid a:hover .val { color: var(--hot); }

/* Reduced-motion users still get the depth, just not the spin. */
@media (prefers-reduced-motion: reduce) {
  .card-face, .hero-index, .stack span, .contact-grid a { transition: none; }
}

/* --------------------------------------------------------------- footer */
.foot { border-top: 1px solid var(--line); padding: 2.2rem 0; }
.foot-in { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: .78rem; color: var(--ink-faint); text-transform: uppercase; letter-spacing: .1em; }

/* --------------------------------------------------------------- reveal */
.reveal { opacity: 0; transform: translateY(22px); }
.reveal.in {
  opacity: 1; transform: none;
  transition: opacity .7s cubic-bezier(.2,.7,.3,1) var(--d, 0s),
              transform .7s cubic-bezier(.2,.7,.3,1) var(--d, 0s);
}
/* No-JS safety: without .in the content would stay invisible forever. */
.no-js .reveal { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}
