:root {
  --blue: #223eea;
  --violet: #3905f4;
  --lime: #c1ff06;
  --ink: #111;
  --ink-2: #242424;
  --muted: #6b6b6b;
  --bg: #fafafa;
  --card: #fff;
  --line: #e5e5e5;
  --radius: 16px;
  --ease: cubic-bezier(.22, 1, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 40px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Urbanist", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; }
p { margin: 0; }
button { font: inherit; cursor: pointer; }
hr { border: 0; border-top: 1px solid var(--line); margin: 0; }

/* ---------- Cursor ---------- */
.cursor {
  position: fixed;
  top: 0; left: 0;
  width: 12px; height: 12px;
  margin: -6px 0 0 -6px;
  border-radius: 99px;
  background: var(--lime);
  pointer-events: none;
  z-index: 1000;
  opacity: 0;
  transition: width .25s var(--ease), height .25s var(--ease), margin .25s var(--ease), opacity .2s;
}
.cursor.is-visible { opacity: 1; }
.cursor.is-hover { width: 36px; height: 36px; margin: -18px 0 0 -18px; mix-blend-mode: difference; }
@media (hover: none) { .cursor { display: none; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 25px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1.5px;
  line-height: 20px;
  transition: transform .2s var(--ease), background-color .2s, color .2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-lime { background: var(--lime); color: #000; }
.btn-blue { background: var(--blue); color: #fff; }
.btn-blue:hover { background: var(--violet); }
.btn-sm { padding: 9px 18px; font-size: 13px; letter-spacing: 1px; }
.btn.is-disabled { cursor: default; transform: none; }

/* ---------- Menu ---------- */
.menu {
  position: fixed;
  inset: 0 0 auto;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 40px;
  pointer-events: none;
}
.menu > * { pointer-events: auto; }
.menu-pill, .menu-links {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border-radius: 100px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .08);
}
.menu-pill { padding: 6px 20px 6px 6px; font-weight: 500; }
.menu-pill img { width: 40px; height: 40px; border-radius: 50%; }
.menu-links { padding: 6px; gap: 2px; font-weight: 500; font-size: 15px; }
.menu-links a { padding: 8px 16px; border-radius: 100px; transition: background-color .2s; }
.menu-links a:hover, .menu-links a[aria-current="page"] { background: #f1f1f1; }
.menu-links .menu-cta, .menu-links .menu-cta:hover { background: var(--blue); color: #fff; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 140px 24px 120px;
  color: #fff;
  text-align: center;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, #4a1dff 0%, var(--violet) 55%, #2c03c4 100%);
  will-change: inset, border-radius;
}
/* Fine dot grid, fading out towards the edges */
.hero-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .22) 1px, transparent 1.2px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 20%, transparent 75%);
          mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, #000 20%, transparent 75%);
}
.hero-inner { display: flex; flex-direction: column; align-items: center; }
.hero-title {
  font-size: clamp(48px, 8vw, 112px);
  font-weight: 600;
  letter-spacing: -.03em;
  line-height: 1;
}
.letter { display: inline-block; transition: color .3s; }
.word { display: inline-block; white-space: nowrap; }
.word.is-accent { color: var(--lime); position: relative; }
/* Light sweep across the accent word, repeating every few seconds */
.word.is-accent::after {
  content: attr(data-shine);
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .95) 50%, transparent 65%) no-repeat;
  background-size: 250% 100%;
  background-position: 130% 0;
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
  pointer-events: none;
  animation: shine 5s ease-in-out 1.6s infinite;
}
@keyframes shine { 0% { background-position: 130% 0; } 35%, 100% { background-position: -30% 0; } }
.nowrap { white-space: nowrap; }
.hero-title .letter { animation: letter-in .9s var(--ease) both; animation-delay: calc(var(--i) * 35ms + 100ms); }
@keyframes letter-in { from { opacity: 0; transform: translateY(.5em) rotate(4deg); filter: blur(6px); } }
.hero-sub { margin-top: 28px; font-size: 19px; max-width: 640px; text-wrap: balance; opacity: .9; animation: fade-up .9s var(--ease) .7s both; }
.hero .btn { margin-top: 36px; animation: fade-up .9s var(--ease) .85s backwards; }
@keyframes fade-up { from { opacity: 0; transform: translateY(16px); } }
.btn-arrow { gap: 10px; box-shadow: 0 0 0 0 rgba(193, 255, 6, .5); }
.btn-arrow span { display: inline-block; transition: transform .3s var(--ease); }
.btn-arrow:hover { box-shadow: 0 10px 40px -8px rgba(193, 255, 6, .6); }
.btn-arrow:hover span { transform: translateX(4px); }
.hero-skills {
  position: absolute;
  bottom: 40px;
  left: 0; right: 0;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0 24px;
  list-style: none;
}
.hero-skills li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  color: var(--ink);
  border-radius: 100px;
  padding: 4px 12px;
  font-size: 14px;
  font-weight: 500;
  transition: transform .3s var(--ease);
  animation: fade-up .7s var(--ease) backwards;
}
.hero-skills li:hover { transform: translateY(-3px); }
.hero-skills li:nth-child(1) { animation-delay: 1s; }
.hero-skills li:nth-child(2) { animation-delay: 1.06s; }
.hero-skills li:nth-child(3) { animation-delay: 1.12s; }
.hero-skills li:nth-child(4) { animation-delay: 1.18s; }
.hero-skills li:nth-child(5) { animation-delay: 1.24s; }
.hero-skills li:nth-child(6) { animation-delay: 1.3s; }
.hero-skills li.is-ai { background: var(--lime); font-weight: 600; }
.hero-skills li.is-ai svg { width: 14px; height: 14px; fill: currentColor; }
.hero-skills li.is-outline { background: transparent; color: #fff; border: 1px solid #fff; }

/* ---------- Logos ---------- */
.logos { padding: 32px 0 0; text-align: center; }
.logos-label { color: var(--muted); font-size: 15px; margin-bottom: 24px; }
.marquee {
  position: relative;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee-track {
  display: flex;
  align-items: center;
  gap: 72px;
  width: max-content;
  animation: marquee 40s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track img { height: 28px; width: auto; filter: grayscale(1); opacity: .8; transition: filter .3s, opacity .3s; }
.marquee-track img.is-mark { height: 40px; }
.marquee-track img:hover { filter: none; opacity: 1; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { padding: 120px 40px 0; max-width: 1240px; margin: 0 auto; }
.section-head { text-align: center; display: flex; flex-direction: column; align-items: center; margin-bottom: 40px; }
.section-icon { width: 44px; height: 44px; margin-bottom: 12px; }
/* Light "poke" on hover: press in, then spring back with a small wobble */
.section-icon.is-in:hover { animation: poke .7s var(--ease); }
@keyframes poke {
  0% { transform: none; }
  20% { transform: scale(.88) rotate(-6deg); }
  45% { transform: scale(1.08) rotate(4deg); }
  70% { transform: scale(.97) rotate(-2deg); }
  100% { transform: none; }
}
.h2 { font-size: clamp(28px, 3vw, 36px); font-weight: 600; color: var(--ink-2); }
.lead { color: var(--muted); font-size: 17px; font-weight: 500; margin-top: 8px; max-width: 520px; }
.reveal-title .char { display: inline-block; }

/* ---------- Bento ---------- */
.bento {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-areas:
    "latest latest tools tools"
    "latest latest exp   exp"
    "read   read   touch touch";
  gap: 12px;
}
.card {
  background: var(--card);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .03);
}
.card-head { display: flex; align-items: center; gap: 8px; }
.card-head img { width: 20px; height: 20px; }
.card-head h3 { font-size: 15px; font-weight: 600; }
.card .btn { align-self: flex-end; margin-top: auto; }
.card h4 { font-size: 22px; font-weight: 600; }

.card-latest { grid-area: latest; position: relative; padding: 0; min-height: 480px; background: #dfe8fb; color: #fff; isolation: isolate; transform: translateZ(0); -webkit-mask-image: -webkit-radial-gradient(white, black); }
.card-latest video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); backface-visibility: hidden; }
.card-latest:hover video { transform: scale(1.04); }
.latest-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
  background: linear-gradient(180deg, rgba(10, 14, 40, 0) 40%, rgba(10, 14, 40, .08) 52%, rgba(10, 14, 40, .3) 64%, rgba(10, 14, 40, .6) 80%, rgba(10, 14, 40, .85) 100%);
  transform: translateZ(0);
}
.latest-badge {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: var(--ink);
  border-radius: 100px;
  padding: 7px 14px 7px 10px;
  font-size: 14px;
  font-weight: 600;
}
.latest-badge img { width: 18px; height: 18px; }
.latest-info { max-width: calc(100% - 72px); }
.latest-info h3 { font-size: 32px; font-weight: 600; }
.latest-info p { font-size: 16px; opacity: .9; margin-top: 4px; }
.latest-arrow {
  position: absolute;
  right: 24px; bottom: 24px;
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--lime);
  color: #000;
  display: grid;
  place-items: center;
  font-size: 22px;
  transition: transform .4s var(--ease);
}
.card-latest:hover .latest-arrow { transform: rotate(45deg); }

.card-tools { grid-area: tools; }
.toolbox {
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
  margin: -10px -24px;
  padding: 10px 0;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.tool-row { display: flex; width: max-content; animation: tools 30s linear infinite; }
.tool-row.is-reverse { animation-direction: reverse; }
.card-tools:hover .tool-row { animation-play-state: paused; }
.tool-row img { width: 64px; height: 64px; margin-right: 16px; object-fit: contain; border-radius: 15px; transition: transform .3s var(--ease); }
.tool-row img:hover { transform: translateY(-4px) scale(1.06); }
@keyframes tools { to { transform: translateX(-50%); } }

.card-reading { grid-area: read; }
.reading { flex: 1; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.reading-text { align-self: center; }
.reading-text p { color: var(--muted); margin-top: 6px; }
.book { width: 40%; max-width: 200px; margin-bottom: -60px; border-radius: 4px; box-shadow: 0 18px 40px rgba(0, 0, 0, .18); transform: rotate(4deg); transition: transform .5s var(--ease); }
.reading-meta { display: inline-block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 8px; }
.reading-text h4 { text-wrap: balance; }
.reading-link { display: inline-flex; gap: 6px; margin-top: 14px; color: var(--blue); font-weight: 600; font-size: 15px; }
.reading-link span { transition: transform .3s var(--ease); }
.card-reading:hover .reading-link span { transform: translate(2px, -2px); }
.card-reading:hover .book { transform: translateY(-10px) rotate(0deg); }

.card-touch { grid-area: touch; background: linear-gradient(180deg, #fff, #f3f3f3); }
.touch { flex: 1; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.touch-text { align-self: center; }
.touch-text p { color: var(--muted); margin-top: 6px; max-width: 280px; }
.envelope { position: relative; flex-shrink: 0; width: 260px; aspect-ratio: 1; margin: -30px 0 -52px; }
.envelope img { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.envelope-paper {
  position: absolute;
  left: 21%; right: 21%;
  top: 36%; bottom: 24%;
  background: #fff;
  border-radius: 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .08);
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 10px;
  transition: transform .5s var(--ease);
}
.card .envelope-paper .btn { align-self: auto; margin-top: 0; padding: 8px 12px; font-size: 13px; letter-spacing: .3px; white-space: nowrap; }
.card-touch:hover .envelope-paper { transform: translateY(-34%); }
.envelope-front { z-index: 2; }
@media (hover: none) { .envelope-paper { transform: translateY(-34%); } }

.card-exp { grid-area: exp; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; text-align: center; flex: 1; align-items: center; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat-num { color: var(--blue); font-size: 52px; font-weight: 600; line-height: 1.1; display: flex; justify-content: center; align-items: baseline; }
.stat-num small { font-size: 16px; color: var(--ink); font-weight: 600; margin-left: 2px; }
.stat p { font-size: 14px; color: var(--muted); margin-top: 4px; }

/* ---------- Work ---------- */
.work { display: grid; grid-template-columns: 320px 1fr; gap: 60px; align-items: start; }
.work-head { position: sticky; top: 120px; }
.work-head .lead { margin-left: 0; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.filter {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 100px;
  padding: 6px 14px;
  font-size: 14px;
  font-weight: 500;
  transition: background-color .2s, color .2s, border-color .2s;
}
.filter:hover { border-color: var(--ink); }
.filter.is-active { background: var(--ink); border-color: var(--ink); color: #fff; }

.projects { display: grid; grid-template-columns: repeat(2, 1fr); gap: 48px 24px; }
.project { display: flex; flex-direction: column; gap: 10px; }
.project.is-hidden { display: none; }
.project-media {
  aspect-ratio: 1;
  border-radius: var(--radius);
  overflow: hidden;
  background: #eef0fb;
  border: 1px solid var(--line);
  margin-bottom: 6px;
  display: grid;
  place-items: center;
}
.project-media video, .project-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.project:hover .project-media video, .project:hover .project-media img { transform: scale(1.03); }
.project-media.is-framed { padding: 28px; background: linear-gradient(160deg, #eef0fb, #dfe4fb); }
.project-media.is-framed video, .project-media.is-framed img { height: auto; object-fit: contain; border-radius: 10px; box-shadow: 0 20px 40px rgba(34, 62, 234, .15); }
.project-media.is-dark { background: linear-gradient(160deg, #1a1a1a, #000); }
.project-media.is-blue { background: #4681f4; }
.project-media.is-blue img { box-shadow: none; }
.project h3 { font-size: 19px; font-weight: 600; }
.project p { color: var(--muted); font-size: 16px; }
.project .btn { align-self: flex-start; margin-top: 6px; }

.tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.tags li { border: 1px solid var(--line); background: #fff; border-radius: 100px; padding: 2px 10px; font-size: 13px; font-weight: 500; }
.tags li.is-lime { background: var(--lime); border-color: var(--lime); }

/* ---------- Gallery ---------- */
.gallery { padding: 140px 0 0; overflow: hidden; display: flex; flex-direction: column; gap: 16px; }
.gallery-row { display: flex; gap: 16px; width: max-content; will-change: transform; }
.gallery-row img { width: clamp(260px, 30vw, 440px); aspect-ratio: 1728 / 1117; object-fit: cover; border-radius: 12px; background: #fff; }

/* ---------- Testimonials ---------- */
.testimonials { max-width: none; padding-left: 0; padding-right: 0; }
.slider-track {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 0 calc(50vw - min(380px, 43vw));
}
.slider-track::-webkit-scrollbar { display: none; }
.quote-card {
  flex: 0 0 min(760px, 86vw);
  scroll-snap-align: center;
  margin: 0;
  background: #fff;
  border-radius: var(--radius);
  padding: 40px;
  display: grid;
  grid-template-columns: 56px 1fr;
  align-content: center;
  gap: 24px;
  opacity: .3;
  transition: opacity .4s;
}
.quote-card.is-active { opacity: 1; }
.quote-mark { width: 48px; }
.quote-card blockquote { margin: 0; font-size: 17px; font-weight: 400; line-height: 1.6; color: #333; }
.quote-card figcaption, .case-quote figcaption { display: flex; align-items: center; gap: 12px; margin-top: 24px; }
.quote-card figcaption img, .case-quote figcaption img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
figcaption span { display: flex; flex-direction: column; font-size: 14px; color: var(--muted); }
figcaption strong { color: var(--ink); font-size: 15px; font-weight: 600; }
.slider-nav { display: flex; justify-content: center; align-items: center; gap: 16px; margin-top: 32px; }
.slider-dots { display: flex; align-items: center; gap: 6px; }
.slider-dot {
  width: 8px; height: 8px;
  padding: 0;
  border: 0;
  border-radius: 100px;
  background: #d3d3d3;
  transition: width .4s var(--ease), background-color .3s;
}
.slider-dot:hover { background: #a3a3a3; }
.slider-dot.is-active { width: 28px; background: var(--blue); }
.slider-btn {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 0;
  background: #e8e8e8;
  display: grid;
  place-items: center;
  transition: background-color .2s;
}
.slider-btn:hover { background: var(--lime); }
.slider-btn img { width: 9px; }

/* ---------- Footer ---------- */
.footer { background: var(--blue); color: #fff; margin-top: 140px; padding: 80px 40px 40px; }
.footer-inner { max-width: 1160px; margin: 0 auto; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.footer-title { font-size: clamp(40px, 6vw, 72px); font-weight: 600; margin-bottom: 24px; }
.footer-link { font-size: 20px; font-weight: 500; transition: color .2s; }
.footer-link:hover { color: var(--lime); }
.footer hr { width: 100%; border-color: rgba(255, 255, 255, .5); margin: 40px 0 16px; }
.footer-copy { font-size: 15px; opacity: .85; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(40px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: var(--d, 0ms); }
.reveal[data-reveal="zoom"] { transform: scale(.94); }
.reveal[data-reveal="fade"] { transform: none; }
.reveal[data-reveal="left"] { transform: translateX(-40px); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal-title .char { opacity: 0; transform: translateY(.6em); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal-title.is-in .char { opacity: 1; transform: none; }

/* ---------- Case study ---------- */
.case-cover { height: 52vh; min-height: 320px; background-size: cover; background-position: center; }
.case {
  max-width: 1240px;
  margin: -80px auto 0;
  padding: 0 40px;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 60px;
  align-items: start;
  position: relative;
}
.case-meta {
  position: sticky;
  top: 120px;
  background: #fff;
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .05);
}
.case-meta h2 { font-size: 14px; font-weight: 500; color: #8a8a8a; }
.case-meta p { font-weight: 600; font-size: 17px; }
.case-meta hr { margin: 8px 0; }
.case-meta .btn { margin-top: 4px; }
.case-logo { width: 110px; }
.case-body { max-width: 820px; padding-top: 110px; display: flex; flex-direction: column; gap: 20px; }
.case-body > p, .case-body li { font-size: 18px; line-height: 1.65; color: #2a2a2a; }
.case-body h2 { font-size: 32px; font-weight: 600; margin-top: 40px; }
.case-body h3 { font-size: 22px; font-weight: 600; margin-top: 16px; }
.case-title { font-size: clamp(36px, 5vw, 64px); font-weight: 600; }
.case-role { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; font-size: 17px; }
.case-tools { display: flex; align-items: center; gap: 10px; }
.case-tools img { width: 32px; height: 32px; object-fit: contain; }
.case-box { background: #fff; border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 16px; }
.case-box h3 { margin: 0; }
.case-box p { font-size: 18px; line-height: 1.65; }
.case-figure { margin: 0; border-radius: var(--radius); overflow: hidden; background: #fff; border: 1px solid var(--line); }
.case-figure.is-video video { width: 100%; }
.zoomable { cursor: zoom-in; }
.case-note { display: flex; gap: 20px; align-items: flex-start; background: #fff; border-radius: var(--radius); padding: 24px; }
.case-note img { width: 48px; flex-shrink: 0; }
.case-note p { font-size: 17px; line-height: 1.6; }
.highlight { font-weight: 600; }
.highlight::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--lime); margin-right: 10px; }
.case-list { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 10px; }
.case-list li::marker { color: var(--blue); }
.case-quote { margin: 20px 0 0; background: var(--blue); color: #fff; border-radius: var(--radius); padding: 40px; }
.case-quote blockquote { margin: 0; font-size: 22px; line-height: 1.5; font-weight: 500; }
.case-quote figcaption span, .case-quote figcaption strong { color: #fff; }
.case-quote figcaption { border-top: 1px solid rgba(255, 255, 255, .3); padding-top: 24px; }
.learnings { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.case-back { align-self: flex-start; margin-top: 40px; }
.page-case .footer { margin-top: 120px; }

.lightbox { border: 0; padding: 0; background: transparent; max-width: 94vw; max-height: 94vh; }
.lightbox::backdrop { background: rgba(0, 0, 0, .8); }
.lightbox img { max-width: 94vw; max-height: 94vh; border-radius: 12px; cursor: zoom-out; }

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
  .bento { grid-template-columns: 1fr 1fr; grid-template-areas: "latest latest" "tools tools" "exp exp" "read touch"; }
  .reading, .touch { flex-direction: column; align-items: center; text-align: center; }
  .card-latest { min-height: 0; aspect-ratio: 1; }
  .work { grid-template-columns: 1fr; gap: 32px; }
  .work-head { position: static; text-align: center; display: flex; flex-direction: column; align-items: center; }
  .work-head .lead { margin: 8px auto 0; }
  .case { grid-template-columns: 1fr; gap: 0; }
  .case-meta { position: static; display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px 24px; }
  .case-meta hr { display: none; }
  .case-body { padding-top: 48px; }
}
@media (max-width: 767px) {
  .menu { padding: 16px; }
  .hero-title { font-size: 68px; }
  .hero-sub { font-size: 17px; }
  .menu-pill { padding-right: 6px; }
  .menu-pill span { display: none; }
  .menu-links { font-size: 14px; }
  .menu-links a { padding: 8px 12px; }
  .section { padding: 90px 16px 0; }
  .projects { grid-template-columns: 1fr; }
  .bento { grid-template-columns: 1fr; grid-template-areas: "latest" "tools" "exp" "read" "touch"; }
  .stat-num { font-size: 40px; }
  .latest-info h3 { font-size: 26px; }
  .latest-info p { font-size: 14px; }
  .latest-arrow { width: 44px; height: 44px; font-size: 18px; }

  .quote-card { grid-template-columns: 1fr; padding: 28px; gap: 12px; }
  .quote-mark { width: 36px; }
  .footer { padding: 60px 16px 32px; }
  .case { padding: 0 16px; }
  .learnings { grid-template-columns: 1fr; }
  .case-quote { padding: 28px; }
  .case-quote blockquote { font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal, .reveal-title .char { opacity: 1; transform: none; }
}

/* ---------- Project links ---------- */
.project { position: relative; }
.project-link { position: absolute; inset: 0; z-index: 2; border-radius: var(--radius); }
.project-media { position: relative; }
.project-arrow {
  position: absolute;
  right: 16px; bottom: 16px;
  z-index: 1;
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--lime);
  color: #000;
  display: grid;
  place-items: center;
  font-size: 20px;
  opacity: 0;
  transform: scale(.6);
  transition: opacity .35s var(--ease), transform .45s var(--ease);
}
.project.is-link:hover .project-arrow { opacity: 1; transform: scale(1) rotate(45deg); }
.project.is-link:hover h3 { color: var(--blue); }
.project h3 { transition: color .2s; }
@media (hover: none) { .project-arrow { opacity: 1; transform: none; } }

/* ---------- How I use AI ---------- */
.ai-panel {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  padding: 56px 40px 40px;
  color: #fff;
  background: radial-gradient(120% 90% at 50% 0%, #4a1dff 0%, var(--violet) 55%, #2c03c4 100%);
  isolation: isolate;
}
.ai-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: radial-gradient(rgba(255, 255, 255, .2) 1px, transparent 1.2px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 15%, transparent 75%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 15%, transparent 75%);
}
.ai-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; counter-reset: step; }
.ai-step {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px;
  border-radius: 20px;
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(255, 255, 255, .14);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  transition: transform .4s var(--ease), border-color .3s, background-color .3s;
}
.ai-step:hover { transform: translateY(-6px); border-color: rgba(193, 255, 6, .6); background: rgba(255, 255, 255, .1); }
/* Thin connector between steps */
.ai-step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 38px; right: -12px;
  width: 12px; height: 1px;
  background: rgba(193, 255, 6, .6);
}
.ai-num { color: var(--lime); font-size: 14px; font-weight: 700; letter-spacing: 1.5px; }
.ai-step h3 { font-size: 20px; font-weight: 600; }
.ai-step p { font-size: 15px; line-height: 1.55; color: rgba(255, 255, 255, .78); }
.ai-tools { display: flex; gap: 8px; margin-top: auto; padding-top: 10px; }
.ai-tools img { width: 32px; height: 32px; border-radius: 8px; object-fit: contain; background: #fff; padding: 3px; }
.ai-motto {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 40px;
  font-size: clamp(22px, 2.6vw, 32px);
  font-weight: 600;
  letter-spacing: -.01em;
}
.ai-spark {
  width: 28px; height: 28px;
  background: var(--lime);
  -webkit-mask: url("../assets/images/icon-latest.svg") center / contain no-repeat;
          mask: url("../assets/images/icon-latest.svg") center / contain no-repeat;
}

.footer-social { display: inline-flex; align-items: center; gap: 10px; }
.footer-social svg { width: 20px; height: 20px; fill: currentColor; }

@media (max-width: 991px) {
  .ai-steps { grid-template-columns: 1fr 1fr; }
  .ai-step::after { display: none; }
}
@media (max-width: 767px) {
  .ai-panel { padding: 28px 16px 24px; border-radius: 24px; }
  .ai-steps { grid-template-columns: 1fr; }
  .ai-motto { margin-top: 28px; }
}

/* ---------- Tooltip ---------- */
.tooltip {
  position: fixed;
  z-index: 999;
  padding: 7px 14px;
  border-radius: 10px;
  background: #1a1a1a;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, calc(-100% + 6px));
  transition: opacity .2s, transform .25s var(--ease);
}
.tooltip::after {
  content: "";
  position: absolute;
  left: 50%; top: calc(100% - 1px);
  border: 7px solid transparent;
  border-top-color: #1a1a1a;
  transform: translateX(-50%);
}
.tooltip.is-visible { opacity: 1; transform: translate(-50%, -100%); }
.ai-tools img { transition: transform .3s var(--ease); }
.ai-tools img:hover { transform: translateY(-3px); }

/* ---------- Language switch ---------- */
.lang-switch {
  display: flex;
  align-items: center;
  margin-left: auto;
  margin-right: -6px;
  padding: 3px;
  border-radius: 100px;
  background: #f1f1f1;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .08);
}
.lang-switch a { padding: 5px 10px; border-radius: 100px; font-size: 13px; font-weight: 600; color: var(--muted); transition: background-color .2s, color .2s; }
.lang-switch a:hover { color: var(--ink); }
.lang-switch a[aria-current] { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .1); }
@media (max-width: 767px) {
  .menu { gap: 6px; padding: 16px 12px; }
  .menu > * { flex-shrink: 0; }
  .menu-pill { padding: 4px; }
  .menu-pill img { width: 36px; height: 36px; }
  .lang-switch { margin-right: 0; }
  .lang-switch a { padding: 5px 8px; font-size: 12px; }
  .menu-links { padding: 4px; }
  .menu-links a { padding: 7px 9px; font-size: 13px; white-space: nowrap; }
}
