/* ============================================================
   Bharat Jaju — personal site
   Dark, minimal, Linear-inspired. One stylesheet, two layouts:
   .landing (home) and .article (case studies / projects).
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

/* ----- Tokens ------------------------------------------------ */
:root {
  --bg:            #08090A;
  --surface:       #101113;
  --surface-hover: #15171A;
  --border:        rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.17);
  --rail:          rgba(255, 255, 255, 0.13);

  --text-strong:   #F4F5F6;
  --text:          #DDDFE2;
  --text-muted:    #969BA2;
  --text-faint:    #6A6F77;

  --accent:        #7C8BFF;
  --accent-soft:   rgba(124, 139, 255, 0.14);
  --ok:            #57CB8B;
  --ok-glow:       rgba(87, 203, 139, 0.20);

  --sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  --maxw: 1060px;
  --radius: 14px;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
}

/* Whisper-quiet glow at the top — static, never animated */
body::before {
  content: "";
  position: fixed;
  top: -260px;
  left: 50%;
  width: 900px;
  height: 600px;
  transform: translateX(-50%);
  background: radial-gradient(50% 50% at 50% 50%, rgba(124, 139, 255, 0.10), transparent 70%);
  pointer-events: none;
  z-index: 0;
}

::selection { background: var(--accent-soft); color: var(--text-strong); }

a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 32px; }

/* ----- Shared bits ------------------------------------------ */
.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-faint);
  display: flex;
  align-items: center;
  gap: 9px;
}
.eyebrow::before {
  content: "";
  width: 14px;
  height: 1px;
  background: var(--border-strong);
}

.lead {
  font-size: clamp(16.5px, 2vw, 19px);
  line-height: 1.65;
  color: var(--text);
  max-width: 660px;
}
.lead a {
  color: var(--text-strong);
  text-decoration: underline;
  text-decoration-color: var(--text-faint);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.18s ease;
}
.lead a:hover { text-decoration-color: var(--accent); }

.tag-row { display: flex; flex-wrap: wrap; gap: 8px; }
.tag {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-muted);
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 5px 11px;
  border-radius: 8px;
}

/* main column */
main { flex: 1; width: 100%; position: relative; z-index: 1; }

.section { padding: 60px 0; border-top: 1px solid var(--border); }
.section-head { margin-bottom: 34px; }
.section-head .lead { margin-top: 18px; }

/* ============================================================
   LANDING
   ============================================================ */
.landing { padding-bottom: 16px; }

/* ----- Hero -------------------------------------------------- */
.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 56px;
  align-items: center;
  padding: clamp(64px, 12vw, 104px) 0 64px;
}
.hero-text { min-width: 0; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 6px 13px 6px 11px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}
a.status {
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}
a.status:hover { border-color: var(--border-strong); background: var(--surface-hover); color: var(--text-strong); }
.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  flex-shrink: 0;
  animation: beacon-pulse 2.4s ease-out infinite;
}

/* the live "actively looking" beacon (top badge + roadmap) */
@keyframes beacon-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(87, 203, 139, 0.55); }
  70%  { box-shadow: 0 0 0 9px rgba(87, 203, 139, 0); }
  100% { box-shadow: 0 0 0 0 rgba(87, 203, 139, 0); }
}

.hero-name {
  font-size: clamp(38px, 6.5vw, 56px);
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1.02;
  color: var(--text-strong);
  margin-top: 22px;
}
.hero-tagline {
  font-size: clamp(17px, 2.4vw, 21px);
  line-height: 1.5;
  color: var(--text-muted);
  margin-top: 18px;
  max-width: 34ch;
}

.hero-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 17px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 11px;
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}
.hero-link:hover { border-color: var(--border-strong); background: var(--surface-hover); color: var(--text-strong); }
.hero-link svg { width: 16px; height: 16px; flex-shrink: 0; }

/* photo / monogram */
.hero-photo {
  position: relative;
  width: clamp(132px, 20vw, 184px);
  aspect-ratio: 4 / 5;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: linear-gradient(150deg, #1b1d22, #0d0e10);
  flex-shrink: 0;
}
.hero-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}
.hero-photo .monogram {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(40px, 7vw, 56px);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-faint);
}

/* ----- Looking-for tags -------------------------------------- */
.lookingfor { scroll-margin-top: 40px; }
.lookingfor .tag-row { margin-top: 26px; }

/* ----- Roadmap ----------------------------------------------- */
.roadmap {
  --rmgap: 24px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--rmgap);
  margin-top: 40px;
}
.milestone { position: relative; min-width: 0; }

.milestone__marker { position: relative; height: 14px; margin-bottom: 20px; }
.milestone__node {
  position: absolute;
  left: 0;
  top: 0;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text-faint);
  box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px var(--border);
  z-index: 1;
}
.milestone__marker::after {
  content: "";
  position: absolute;
  top: 6.5px;
  left: 14px;
  right: calc(var(--rmgap) * -1);
  height: 1.5px;
  background: var(--rail);
  z-index: 0;
}
.milestone:last-child .milestone__marker::after { display: none; }

/* most-recent completed role — solid node, no glow (the beacon now sits after it) */
.milestone--active .milestone__node {
  background: var(--text);
  box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px var(--border);
}
/* live "actively looking" beacon, sitting on the rail between the last role and Open */
.milestone__beacon {
  position: absolute;
  z-index: 2;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--ok);
  top: 1.5px;
  /* sit ~70% of the way from the last role toward Open — still in transition, not done */
  left: calc(1.5px + (100% + var(--rmgap)) * 0.7);
  animation: beacon-pulse 2.4s ease-out infinite;
}
/* the segment leading into the open node reads as "unwritten" */
.milestone--active .milestone__marker::after {
  background: none;
  border-top: 1.5px dashed var(--rail);
  height: 0;
}
/* open / future */
.milestone--open .milestone__node {
  background: transparent;
  border: 1.5px dashed var(--ok);
  box-shadow: 0 0 0 4px var(--bg);
}

.milestone__meta { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; flex-wrap: wrap; }
.milestone__period { font-family: var(--mono); font-size: 12px; color: var(--text-muted); white-space: nowrap; }

.pill {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  color: var(--text-faint);
  background: var(--surface);
  white-space: nowrap;
}
.pill--active { color: var(--accent); border-color: rgba(124, 139, 255, 0.35); background: var(--accent-soft); }
.pill--open   { color: var(--ok); border-color: rgba(87, 203, 139, 0.35); background: rgba(87, 203, 139, 0.10); }

.milestone__title { font-size: 17px; font-weight: 600; color: var(--text-strong); letter-spacing: -0.01em; }
.milestone__role { font-size: 13px; color: var(--text-muted); margin-top: 3px; }
.milestone__desc { font-size: 14px; line-height: 1.62; color: var(--text-muted); margin-top: 12px; }
.milestone__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  transition: gap 0.18s ease, opacity 0.18s ease;
}
.milestone__link:hover { gap: 10px; opacity: 0.85; }
.milestone__link svg { width: 15px; height: 15px; flex-shrink: 0; }

/* ----- Projects ---------------------------------------------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(278px, 1fr));
  gap: 16px;
  margin-top: 40px;
}
.project {
  display: flex;
  flex-direction: column;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}
a.project:hover { border-color: var(--border-strong); background: var(--surface-hover); transform: translateY(-2px); }

.project__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
  display: grid;
  place-items: center;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.project__icon svg { width: 19px; height: 19px; }
a.project:hover .project__icon { color: var(--accent); border-color: rgba(124, 139, 255, 0.35); }

.project__title { font-size: 16px; font-weight: 600; color: var(--text-strong); letter-spacing: -0.01em; }
.project__desc { font-size: 14px; line-height: 1.6; color: var(--text-muted); margin-top: 9px; flex: 1; }

.project__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 20px;
}
.project__meta { font-family: var(--mono); font-size: 12px; color: var(--text-faint); }
.project__arrow {
  color: var(--text-faint);
  transition: color 0.18s ease, transform 0.18s ease;
  display: inline-flex;
}
.project__arrow svg { width: 16px; height: 16px; }
a.project:hover .project__arrow { color: var(--accent); transform: translateX(3px); }
.project__wip {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ok);
  border: 1px solid rgba(87, 203, 139, 0.30);
  background: rgba(87, 203, 139, 0.09);
  padding: 3px 8px;
  border-radius: 6px;
  white-space: nowrap;
}
.project__shipped {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
  border: 1px solid var(--border);
  background: var(--bg);
  padding: 3px 8px;
  border-radius: 6px;
  white-space: nowrap;
}
/* pairs a status chip with the arrow on linked, shipped cards */
.project__end { display: inline-flex; align-items: center; gap: 10px; }

/* dual action links (used when a card has more than one destination) */
.project__links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 16px;
  padding-top: 15px;
  border-top: 1px solid var(--border);
}
.project__links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  transition: gap 0.18s ease, opacity 0.18s ease;
}
.project__links a:hover { gap: 9px; opacity: 0.85; }
.project__links a svg { width: 14px; height: 14px; flex-shrink: 0; }

/* ============================================================
   FOOTER (shared)
   ============================================================ */
.site-footer { border-top: 1px solid var(--border); margin-top: 80px; position: relative; z-index: 1; }
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 28px;
  flex-wrap: wrap;
  padding-top: 40px;
  padding-bottom: 52px;
}
.footer-brand strong { color: var(--text-strong); font-size: 15px; font-weight: 600; }
.footer-brand p { color: var(--text-faint); font-size: 13px; margin-top: 7px; line-height: 1.5; }
.footer-brand .sep { color: var(--border-strong); margin: 0 8px; }

.footer-social { display: flex; gap: 12px; }
.footer-social a {
  width: 42px;
  height: 42px;
  border: 1px solid var(--border);
  border-radius: 11px;
  display: grid;
  place-items: center;
  color: var(--text-muted);
  background: var(--surface);
  transition: color 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.footer-social a:hover { color: var(--text-strong); border-color: var(--border-strong); background: var(--surface-hover); }
.footer-social svg { width: 18px; height: 18px; }

/* ============================================================
   ARTICLE (case studies / projects)
   ============================================================ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(8, 9, 10, 0.72);
  backdrop-filter: saturate(140%) blur(10px);
  -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.topbar__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 14px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.topbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--text-strong);
  text-decoration: none;
}
.topbar__brand .arrow { color: var(--text-faint); transition: transform 0.18s ease, color 0.18s ease; }
.topbar__brand:hover .arrow { transform: translateX(-3px); color: var(--text); }
.topbar__links { display: flex; gap: 8px; }
.topbar__links a {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  color: var(--text-muted);
  border: 1px solid transparent;
  transition: color 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}
.topbar__links a:hover { color: var(--text-strong); border-color: var(--border); background: var(--surface); }
.topbar__links svg { width: 17px; height: 17px; }

.article { max-width: 736px; margin: 0 auto; padding: 64px 32px 24px; }

.case-study h1 {
  font-size: clamp(28px, 4.4vw, 38px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text-strong);
  margin-bottom: 14px;
}
.case-study .subtitle {
  font-family: var(--mono);
  font-size: 13.5px;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.case-study h2 {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-faint);
  margin: 0 0 18px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.case-study h2::before { content: ""; width: 14px; height: 1px; background: var(--border-strong); }
.case-study p {
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--text);
  margin-bottom: 16px;
}
.case-study p:last-child { margin-bottom: 0; }
.case-study strong { color: var(--text-strong); font-weight: 600; }
.case-study ul { margin: 0 0 16px 4px; list-style: none; }
.case-study ul li {
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--text);
  margin-bottom: 10px;
  padding-left: 22px;
  position: relative;
}
.case-study ul li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 12px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.case-divider { border: none; border-top: 1px solid var(--border); margin: 40px 0; }

.outcome-row { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 22px; }
.outcome-tag {
  display: inline-block;
  background: var(--accent-soft);
  border: 1px solid rgba(124, 139, 255, 0.30);
  padding: 7px 14px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--text-strong);
}

.case-footer {
  margin-top: 56px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-faint);
}
.case-footer p { font-size: 13px; color: var(--text-faint); margin: 0; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 32px;
    padding-top: clamp(48px, 14vw, 72px);
  }
  .hero-photo { order: -1; }

  /* roadmap → vertical rail */
  .roadmap { display: flex; flex-direction: column; gap: 0; }
  .milestone { display: grid; grid-template-columns: 14px 1fr; gap: 0 20px; padding-bottom: 34px; align-items: start; }
  .milestone:last-child { padding-bottom: 0; }
  /* marker is the left rail (spans full height); everything else stacks in column 2 */
  .milestone__marker { height: auto; margin-bottom: 0; grid-column: 1; grid-row: 1 / span 99; align-self: stretch; }
  .milestone > :not(.milestone__marker) { grid-column: 2; min-width: 0; }
  .milestone__marker::after {
    top: 14px;
    bottom: -34px;
    left: 6.5px;
    right: auto;
    width: 1.5px;
    height: auto;
  }
  .milestone--active { padding-bottom: 60px; }
  .milestone--active .milestone__marker::after {
    border-top: none;
    border-left: 1.5px dashed var(--rail);
    background: none;
    width: 0;
    height: auto;
    bottom: -60px;
  }
  .milestone__beacon { top: auto; right: auto; left: 1.5px; bottom: -45px; }
  .milestone__meta { margin-top: -1px; }
}

@media (max-width: 560px) {
  .container { padding: 0 20px; }
  .topbar__inner { padding: 12px 20px; }
  .article { padding: 48px 20px 16px; }
  .section { padding: 48px 0; }
  .hero-links { width: 100%; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 26px; }
}

/* Respect reduced-motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
  }
}
