/* Homepage — editorial system shared with gf-case.css (pilot for site-wide look).
   Loaded only by index-v2.html while the revamp is under review. */

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

/* Colour, type, measure and rhythm all come from tokens.css. */

html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(circle, rgba(63, 127, 244, .16) 1px, transparent 1.4px) 0 0 / 24px 24px,
    var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img, video { max-width: 100%; display: block; }

/* ── Whole-page watercolor bleed background ── */
.watercolor {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  filter: url(#watercolor-filter);
  opacity: .5;
}

.blob {
  position: absolute;
  border-radius: 50%;
  mix-blend-mode: multiply;
  animation: drift 22s ease-in-out infinite;
}
.blob.blue {
  width: 60vw; height: 60vw; left: 30%; top: 20%;
  background: radial-gradient(circle, rgba(70,140,190,.65) 0%, rgba(70,140,190,.3) 55%, rgba(70,140,190,0) 78%);
  animation-duration: 26s;
}
.blob.teal {
  width: 55vw; height: 55vw; left: 55%; top: 5%;
  background: radial-gradient(circle, rgba(60,175,150,.6) 0%, rgba(60,175,150,.25) 55%, rgba(60,175,150,0) 78%);
  animation-duration: 30s; animation-delay: -6s;
}
.blob.pale {
  width: 32vw; height: 32vw; left: 2%; top: -6%;
  background: radial-gradient(circle, rgba(225,245,240,.95) 0%, rgba(225,245,240,.4) 55%, rgba(225,245,240,0) 75%);
  animation-duration: 34s; animation-delay: -12s;
}
.blob.deep {
  width: 40vw; height: 40vw; left: 40%; top: 40%;
  background: radial-gradient(circle, rgba(45,110,160,.5) 0%, rgba(45,110,160,.2) 55%, rgba(45,110,160,0) 78%);
  animation-duration: 24s; animation-delay: -18s;
}

.droplet {
  position: absolute;
  border-radius: 50%;
  background: rgba(50,130,160,.5);
  mix-blend-mode: multiply;
}

@keyframes drift {
  0%   { transform: translate(0, 0) scale(1); }
  33%  { transform: translate(3%, -4%) scale(1.06); }
  66%  { transform: translate(-2%, 3%) scale(.97); }
  100% { transform: translate(0, 0) scale(1); }
}

/* ── Hero ticker-tape marquee ── */
.hero-marquee {
  margin-top: 44px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}

.marquee-track {
  display: inline-flex;
  white-space: nowrap;
  animation: marquee 26s linear infinite;
  will-change: transform;
}
.hero-marquee:hover .marquee-track { animation-play-state: paused; }

.marquee-track span {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  padding-left: 22px;
}
.marquee-track span::after {
  content: "•";
  margin-left: 22px;
  color: var(--accent);
}

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .blob, .marquee-track { animation: none; }
}

/* ── Appear-on-load / appear-on-scroll reveals ── */
.hero--appear {
  animation: appearUp .9s cubic-bezier(.16,1,.3,1) backwards;
}

@keyframes appearUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  .hero--appear { animation: none; }
}

/* ── Top nav: flat editorial bar (same as /gf) ── */
.top-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 250, 248, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}

.nav-content {
  max-width: 1440px;
  margin: 0 auto;
  padding: 0 48px;
  height: 56px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .08em;
  color: var(--muted);
  transition: color .15s ease;
}
.nav-link:hover { color: var(--ink); }

.nav-separator {
  width: 1px;
  height: 18px;
  background: var(--rule);
}

.social-links {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-left: auto;
}

.social-links a {
  display: flex;
  align-items: center;
  color: var(--muted);
  transition: color .15s ease;
}
.social-links a:hover { color: var(--accent); }
.social-links .ph {
  display: block;
  width: 17px;
  height: 17px;
  font-size: 17px;
  line-height: 17px;
}

/* ── Shell: single centered column, quieter than /gf ── */
.home-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 50px 50px 50px;
}

/* ── Hero ── */
.hero-id {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-avatar {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid var(--rule);
  object-fit: cover;
}

.hero-name {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink);
}

.hero-name span {
  color: var(--faint);
}


.hero-status {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  white-space: nowrap;
}
.hero-status::before {
  content: "";
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  margin-right: 10px;
  vertical-align: 0;
}

.hero-headline {
  margin-top: 54px;
  font-size: clamp(38px, 5vw, 62px);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.06;
  max-width: 20ch;
}

.hero-support {
  margin-top: 24px;
  font-size: 21px;
  font-weight: 400;
  line-height: 1.55;
  color: var(--muted);
  max-width: 46ch;
}
.hero-support strong {
  font-weight: 500;
  color: var(--ink);
}

/* ── Selected work ── */
.work-section { margin-top: 70px; }

.work-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 16px;
}

.work-label {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink);
}

.work-count {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .1em;
  color: var(--faint);
  white-space: nowrap;
}

/* Segmented control: Selected Work / Personal Projects */
.work-tabs {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--rule);
  border-radius: 999px;
}

.work-tab {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 6px 12px;
  border: none;
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}

.work-tab:hover:not(.active) { color: var(--ink); }

.work-tab.active {
  background: var(--ink);
  color: var(--bg);
}

.work-panel[hidden] { display: none; }

/* Project entries — editorial rows, not boxed cards */
.work-entry {
  display: block;
  margin-top: 68px;
}
.work-entry:first-of-type { margin-top: 72px; }

.work-media {
  margin-top: 28px;
  border: 1px solid var(--rule);
  overflow: hidden;
}
.work-media video, .work-media img { width: 100%; }

.work-entry--locked .work-meta { margin-top: 0; }
.work-entry--no-media .work-meta { margin-top: 0; }

.work-lock-icon {
  width: .72em;
  height: .72em;
  margin-right: 10px;
  vertical-align: 4%;
  color: var(--faint);
  flex-shrink: 0;
}

.work-meta {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px 28px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}

.work-index { color: var(--accent); font-weight: 500; }
.work-tags { margin-left: auto; color: var(--faint); text-align: right; }

.work-title {
  margin-top: 14px;
  font-size: clamp(26px, 3vw, 38px);
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.08;
  max-width: 100%;
  transition: color .15s ease;
}

.work-support {
  margin-top: 10px;
  font-size: 18px;
  font-weight: 400;
  color: var(--muted);
  max-width: 52ch;
}

.work-entry:hover .work-title { color: var(--accent); }

/* ── Archive link ── */
.archive-link {
  display: block;
  margin-top: 130px;
  padding-top: 26px;
  border-top: 1px solid var(--ink);
}

.archive-link .work-title { margin-top: 12px; font-size: clamp(24px, 2.6vw, 32px); }
.archive-link:hover .work-title { color: var(--accent); }

/* ── Footer links (Archive + Playground, side by side) ── */
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 40px 64px;
  margin-top: 130px;
  padding-top: 26px;
  border-top: 1px solid var(--ink);
}
.footer-links .footer-link { display: block; }
.footer-links .footer-link .work-title { margin-top: 12px; font-size: clamp(24px, 2.6vw, 32px); }
.footer-links .footer-link:hover .work-title { color: var(--accent); }

/* ── Archive page: intro + compact section spacing ── */
.archive-intro { margin-top: 0; }
.archive-intro .hero-headline { margin-top: 14px; max-width: 20ch; }

/* Archive runs on the same type scale and rhythm as the home work list. */
.archive-page .archive-intro .hero-headline {
  font: 500 24px/1.3 var(--sans);
  letter-spacing: -.035em;
}
.archive-page .archive-intro .hero-support {
  margin-top: 12px;
  font: 400 16px/1.625 var(--sans);
  max-width: 52ch;
}
.archive-page .work-tab,
.archive-page .work-meta { font-family: var(--mono); font-size: 12px; }
.archive-page .work-title { font: 500 24px/1.3 var(--sans); letter-spacing: -.035em; }
.archive-page .work-support { font: 400 16px/1.625 var(--sans); }
.archive-page .work-entry { margin-top: 68px; }
.archive-page .work-entry:first-of-type { margin-top: 40px; }

@media (max-width: 979px) {
  .archive-page .archive-intro .hero-headline,
  .archive-page .work-title { font-size: 22px; }
  .archive-page .work-entry:first-of-type { margin-top: 32px; }
}

/* ── Playground: bounded card grid ── */
.playground-grid {
  margin-top: 72px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
}
.playground-card { display: block; border: 1px solid var(--rule); overflow: hidden; transition: border-color .15s ease; }
.playground-card:hover { border-color: var(--accent); }
.playground-card-media { aspect-ratio: 3 / 2; overflow: hidden; border-bottom: 1px solid var(--rule); }
.playground-card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.playground-card-body { padding: 20px 22px 24px; }
.playground-card .work-meta { margin-top: 0; }
.playground-card-title {
  margin-top: 10px; font-size: 18px; font-weight: 700; letter-spacing: -.01em; line-height: 1.3;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; transition: color .15s ease;
}
.playground-card:hover .playground-card-title { color: var(--accent); }
.playground-card-support {
  margin-top: 8px; font-size: 14px; line-height: 1.55; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.work-section--compact { margin-top: 56px; }
@media (max-width: 720px) { .work-section--compact { margin-top: 40px; } }

/* ── Breakpoints ── */
@media (max-width: 720px) {
  .nav-content { padding: 0 20px; gap: 18px; flex-wrap: wrap; row-gap: 10px; }
  .social-links { margin-left: auto; }

  .home-shell { padding: 72px 18px 100px; }

  .hero-status { margin-left: 0; flex-basis: 100%; }
  .hero-headline { margin-top: 40px; font-size: clamp(38px, 11vw, 48px); }
  .hero-support { font-size: 18px; }

  .work-section { margin-top: 110px; }
  .work-header { flex-direction: column; align-items: flex-start; gap: 16px; }
  .work-tab { padding: 6px 10px; font-size: 10px; }
  .work-entry { margin-top: 70px; }
  .work-entry:first-of-type { margin-top: 32px; }
  .work-tags { margin-left: 0; text-align: left; flex-basis: 100%; }
  .work-support { font-size: 16px; }

  .archive-link { margin-top: 90px; }
  .footer-links { margin-top: 90px; flex-direction: column; gap: 32px; }
  .playground-grid { grid-template-columns: 1fr; margin-top: 48px; gap: 24px; }
}

/* ── Home: narrow identity rail + unchanged work canvas ── */
.home-page {
  --sans: "Geist", system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, monospace;
  font-family: var(--sans);
}
.home-page .home-mobile-nav { display: none; }
.home-page .home-shell {
  max-width: none;
  min-height: 100dvh;
  margin: 0;
  padding: 0;
  display: block;
  align-items: start;
}
.home-rail {
  position: sticky;
  z-index: 60;
  top: 0;
  height: 100dvh;
  padding: 24px 28px 28px;
  border-right: 1px solid var(--rule);
  background: color-mix(in srgb, var(--bg) 96%, var(--surface));
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.rail-top { display: flex; justify-content: flex-end; margin-bottom: 20px; }
.home-rail .hero { margin: 0; }
.home-rail .hero-id { display: block; }
.home-rail .hero-name { display: flex; align-items: center; gap: 10px; }
.home-rail .hero-name-text {
  color: var(--ink);
  font: 500 20px/1.4 var(--sans);
  letter-spacing: -0.02em;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.home-rail .hero-role { margin-top: 6px; color: var(--muted); font: 400 14px/1.6 var(--sans); letter-spacing: -0.01em; }
.home-rail .hero-status {
  display: inline-flex;
  align-items: center;
  gap: 0;
  margin: 0;
  padding: 4px 8px;
  border: 1px solid var(--rule);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font: 400 12px/1.4 var(--sans);
  letter-spacing: -.2px;
  white-space: nowrap;
}
.home-rail .hero-name .hero-status { font-size: 12px; }
.home-rail .hero-status::before { content: ""; width: 6px; height: 6px; margin-right: 4px; border-radius: 50%; background: var(--available); }
/* Headline and project titles share one voice: same family, weight and tracking. */
.home-rail .hero-headline { margin-top: 20px; max-width: 21ch; font: 500 20px/1.3 var(--sans); letter-spacing: -.035em; }
.home-rail .hero-support { margin-top: 14px; max-width: 34ch; color: var(--muted); font: 400 14px/1.6 var(--sans); letter-spacing: -0.01em; }
.home-rail__footer { margin-top: auto; padding-top: 32px; }
.home-rail__nav,
.home-ai-links { display: grid; gap: 8px; }
.home-rail__nav a,
.home-ai-links a,
.home-email { width: fit-content; color: var(--muted); font: 400 14px/1.6 var(--sans); letter-spacing: -0.01em; transition: color .15s ease; }
.home-rail__nav a { position: relative; }
.home-rail__nav a[aria-current='page'] { padding-left: 18px; }
.home-rail__nav a[aria-current='page']::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 8px;
  height: 8px;
  background: var(--accent);
}
.home-rail__nav a[aria-current='page'] { color: var(--ink); font-weight: 500; }
.home-rail__nav a:hover,
.home-ai-links a:hover,
.home-email:hover { color: var(--accent); }
.home-ai-links { margin-top: clamp(28px, 12vh, 108px); padding-top: 0; border-top: 0; gap: 8px; }
.home-ai-links .ai-button { display: inline-flex; align-items: center; gap: 8px; width: 100%; padding: 8px 10px; border: 1px solid var(--rule); border-radius: 6px; background: var(--surface); color: var(--ink); font: 500 13px/1.25 var(--sans); }
.home-ai-links .ai-button:hover { border-color: var(--ink); color: var(--ink); }
.ai-button img { width: 16px; height: 16px; flex: 0 0 16px; }
:root[data-theme='dark'] .ai-button img { filter: invert(1); }
.home-email { display: block; margin-top: 18px; }
.home-social-links { display: flex; align-items: center; gap: 16px; margin-top: 14px; }
.home-social-links a { display: grid; place-items: center; color: var(--muted); transition: color .15s ease; }
.home-social-links a:hover { color: var(--accent); }
.home-social-links svg { width: 20px; height: 20px; fill: currentColor; }
.home-work { min-width: 0; padding: clamp(44px, 6vw, 88px) clamp(32px, 7vw, 120px) 120px; }
.home-work .work-section { max-width: 1120px; margin: 0 auto; }
.home-work .work-entry:first-of-type { margin-top: 40px; }
.home-page .work-tab,
.home-page .work-count,
.home-page .work-meta { font-family: var(--mono); font-size: 12px; }
/* Same voice as the rail headline: 500 weight, -.035em, 1.3 line-height. */
.home-page .work-title { font: 500 24px/1.3 var(--sans); letter-spacing: -.035em; }
.home-page .work-support { font: 400 16px/1.625 var(--sans); }

@media (max-width: 979px) {
  .home-page .home-mobile-nav { display: block; }
  .home-page .home-mobile-nav .nav-content { min-height: 56px; height: auto; padding: 10px 18px; gap: 10px 18px; flex-wrap: wrap; }
  .home-page .home-mobile-nav .social-links { display: flex; margin-left: 0; gap: 15px; }
  .home-page .home-mobile-nav .site-controls { display: none; }
  .home-page .home-shell { display: block; min-height: 0; padding: 0 var(--mobile-content-inset) 100px; }
  .home-rail { position: relative; height: auto; padding: 40px 0 0; border-right: 0; background: transparent; overflow: visible; }
  .home-rail .hero-name { flex-wrap: wrap; }
  .home-rail .hero-status { flex-basis: auto; }
  .home-rail .nike-photo { display: none; }
  .home-rail { overflow: visible; }
  .rail-top { display: none; }
  .home-rail .hero-headline { margin-top: 40px; max-width: 20ch; font-size: 22px; }
  .home-page .work-title { font-size: 22px; }
  .home-rail .hero-support { font-size: 16px; }
  /* The CTA and email follow the intro on mobile instead of being dropped. */
  .home-rail__footer { display: block; margin-top: 28px; }
  .home-rail__nav { display: none; }
  .home-page .home-mobile-nav .social-links { display: none; }
  .home-work { padding: 0; }
  .home-work .work-section { margin-top: 72px; }
}

@media (max-height: 860px) {
  .home-rail { padding-top: 16px; }
  .home-rail .hero-marquee { display: none; }
  .home-rail__footer { padding-top: 20px; }
  .home-ai-links { margin-top: 28px; padding-top: 0; }
  .home-ai-links .ai-button { padding: 8px 10px; }
  .home-email { margin-top: 12px; }
  .home-social-links { margin-top: 10px; }
}

/* Two ways to ask about the work: ChatGPT outlined, Claude filled. */
.home-ai-links .ai-button {
  justify-content: center;
  padding: 11px 12px;
  border-radius: 8px;
  background: var(--paper);
  font-weight: 500;
}
.home-ai-links .ai-button:hover { border-color: var(--ink); }
.home-ai-links .ai-button--claude {
  border-color: var(--claude);
  background: var(--claude);
  color: #fff;
}
.home-ai-links .ai-button--claude:hover {
  border-color: #b8634a;
  background: #b8634a;
  color: #fff;
}
:root[data-theme='dark'] .home-ai-links .ai-button--claude img { filter: none; }

.home-ai-links .ai-icon { width: 16px; height: 16px; flex: 0 0 16px; }
