/* robvb.com — Index direction with Archivo display headings */

:root {
  --bg: #F4F4F2;
  --ink: #0C0C0C;
  --soft: #5E5E5B;
  --body: #3D3D3B;
  --rule: #DAD9D5;
  --chip: #C9C8C3;
  --accent: #FF4D00;
  --accent-text: #C23B00;
  --on-ink: #F4F4F2;
  --on-ink-soft: #A3A39E;

  --display: 'Archivo', 'Arial Black', system-ui, sans-serif;
  --sans: 'Inter Tight', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'DM Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  --pad: clamp(16px, 2.5vw, 36px);
  --gap: clamp(12px, 1.6vw, 24px);
  --tile-h: clamp(220px, 25vw, 360px);
  --ease: cubic-bezier(.2, .8, .2, 1);
}

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

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img { max-width: 100%; }
a { color: inherit; }
a:hover { color: var(--accent-text); }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--accent); color: #fff; }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.nobr { white-space: nowrap; }
.skip { position: absolute; left: var(--pad); top: -60px; z-index: 20; background: var(--ink); color: var(--on-ink); padding: 12px 16px; text-decoration: none; }
.skip:focus, .skip:hover { top: 12px; color: var(--on-ink); }

.wrap { padding-left: var(--pad); padding-right: var(--pad); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap); }
.mono { font-family: var(--mono); font-size: 12px; font-weight: 400; letter-spacing: .04em; text-transform: uppercase; }
.display { font-family: var(--display); font-weight: 800; font-stretch: 125%; text-transform: uppercase; letter-spacing: -.01em; line-height: .9; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 10;
  align-items: center;
  padding-top: 14px; padding-bottom: 14px;
  background: rgba(244, 244, 242, .97);
  border-bottom: 1px solid var(--rule);
}
.brand { grid-column: span 3; display: inline-flex; align-items: center; min-height: 44px; font-size: 17px; text-decoration: none; letter-spacing: .02em; line-height: 1; justify-self: start; }
.nav-who, .nav-clock { grid-column: span 3; color: var(--soft); }
.nav-clock[data-pending] { visibility: hidden; }
.nav-links { grid-column: span 3; display: flex; justify-content: flex-end; gap: clamp(14px, 2vw, 28px); }
.nav-links a { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; min-width: 44px; text-decoration: none; white-space: nowrap; }
.nav-links sup { font-size: 9px; vertical-align: 5px; margin-left: 1px; }

/* Hero */
.hero { padding-top: clamp(56px, 8vw, 128px); padding-bottom: clamp(48px, 6vw, 88px); }
.hero-title { margin: 0; font-size: clamp(40px, 8.15vw, 156px); line-height: .88; }
.hero-title .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .06em; margin-bottom: -.06em; }
.hero-title .w > span { display: inline-block; animation: rise 1.1s var(--ease) both; }
.hero-title .w:nth-child(2) > span { animation-delay: .08s; }
.hero-title .w:nth-child(3) > span { animation-delay: .16s; }
.hero-title .w:nth-child(4) > span { animation-delay: .24s; }
.hero-title sup { font-size: 12px; letter-spacing: .04em; color: var(--soft); vertical-align: top; position: relative; top: 1.2em; margin-left: 12px; white-space: nowrap; animation: fade 1s var(--ease) .8s both; }

.intro { margin-top: clamp(40px, 5vw, 80px); align-items: end; row-gap: 24px; }
.status { grid-column: span 6; margin: 0; display: flex; align-items: center; animation: fade 1s var(--ease) .6s both; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-right: 10px; }
.intro-text { grid-column: 7 / span 6; margin: 0; font-size: clamp(19px, 1.8vw, 27px); line-height: 1.32; letter-spacing: -.018em; font-weight: 500; animation: fade 1s var(--ease) .45s both; }

/* Index */
.index { position: relative; border-top: 1px solid var(--ink); margin-bottom: clamp(88px, 11vw, 168px); }
.rows { list-style: none; margin: 0; padding: 0; }
.row {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap);
  align-items: center; padding: 22px 0;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  transition: color .2s;
}
.row .c-n, .row .c-name, .row .c-what, .row .c-plat { transition: transform .3s var(--ease); }
.row-head { padding: 14px 0; color: var(--soft); }
.row-head .c-name, .row-head .c-what { font-size: 12px; color: inherit; }
.c-n { grid-column: span 1; }
.c-name { grid-column: span 4; font-size: clamp(22px, 2.5vw, 38px); }
.c-what { grid-column: span 4; font-size: 16px; color: var(--body); }
.c-plat { grid-column: span 2; color: var(--soft); }
.c-yr { grid-column: span 1; text-align: right; }
a.row.on { color: var(--ink); }
a.row.on .c-n { color: var(--accent-text); }
a.row.on :is(.c-n, .c-name, .c-what, .c-plat) { transform: translateX(18px); }
@media (hover: hover) and (pointer: fine) {
  a.row:hover { color: var(--ink); }
  a.row:hover .c-n { color: var(--accent-text); }
  a.row:hover :is(.c-n, .c-name, .c-what, .c-plat) { transform: translateX(18px); }
}

.preview {
  position: absolute; left: 0; top: 0; z-index: 3;
  width: clamp(260px, 24vw, 360px); aspect-ratio: 8 / 5;
  pointer-events: none; opacity: 0; scale: .92; transform-origin: left center;
  transition: opacity .25s, scale .3s var(--ease);
  will-change: transform;
}
.preview.on { opacity: 1; scale: 1; }
.preview img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top;
  border-radius: 4px; box-shadow: 0 30px 60px -22px rgba(12, 12, 12, .45);
  opacity: 0; transition: opacity 0s .25s;
}
.preview img.on { opacity: 1; z-index: 1; transition: opacity .2s; }

/* Cases */
.case { padding-top: clamp(56px, 7vw, 104px); border-top: 1px solid var(--ink); margin: 0 var(--pad); }
.case > .wrap { padding-left: 0; padding-right: 0; }
.case-head { align-items: end; row-gap: 20px; margin-bottom: clamp(24px, 3vw, 40px); }
.case-n { grid-column: span 1; align-self: start; padding-top: 10px; }
.case-name { grid-column: span 7; margin: 0; font-size: clamp(36px, 6.6vw, 124px); overflow: hidden; padding-bottom: .04em; }
.case-name span { display: inline-block; }
.case-lede { grid-column: span 4; margin: 0; font-size: 18px; line-height: 1.45; font-weight: 500; letter-spacing: -.01em; }

.strip { position: relative; contain: paint; margin: 0 calc(-1 * var(--pad)); overflow-x: auto; scrollbar-width: thin; scroll-snap-type: x proximity; outline-offset: -2px; padding-bottom: 6px; }
.strip .tile { scroll-snap-align: start; }
.strip.is-marquee { overflow: hidden; scroll-snap-type: none; padding-bottom: 0; touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.strip.is-marquee.dragging { cursor: grabbing; }
.strip img { -webkit-user-drag: none; }
.track { display: flex; gap: 10px; width: max-content; padding: 0 var(--pad); will-change: transform; }
.strip.is-marquee .track { padding: 0; }
.tile { flex: none; margin: 0; height: var(--tile-h); border-radius: 4px; overflow: hidden; position: relative; background: #E6E5E1; }
.tile img { display: block; height: 100%; width: auto; max-width: none; }
.tile.phone { border-radius: clamp(14px, 1.6vw, 22px); }
.tile.sq { aspect-ratio: 1; background: var(--tbg); display: flex; align-items: center; justify-content: center; }
.tile .mark { height: 34%; width: auto; }
.tile .mark.big { height: 62%; }
.tile .mark.invert { filter: brightness(0) invert(1); }
.tile.type { aspect-ratio: 4 / 5; display: flex; flex-direction: column; justify-content: space-between; padding: 18px 20px; background: var(--tbg); color: var(--fg); box-shadow: inset 0 0 0 1px rgba(12, 12, 12, .06); }
.tile.type b { font-weight: 400; font-size: calc(var(--tile-h) * .42); line-height: .9; }
.t-geist { font-family: 'Geist', var(--sans); font-weight: 700 !important; letter-spacing: -.05em; }
.t-bagel { font-family: 'Bagel Fat One', var(--sans); }
.t-anton { font-family: 'Anton', var(--sans); }
.t-nunito { font-family: 'Nunito', var(--sans); font-weight: 900 !important; letter-spacing: -.03em; }
.t-fredoka { font-family: 'Fredoka', var(--sans); font-weight: 700 !important; }
.tile.sw { aspect-ratio: 3 / 5; display: flex; flex-direction: column; background: none; }
.tile.sw span { flex: 1; display: flex; align-items: flex-end; padding: 10px 12px; background: var(--c); color: var(--t); font-family: var(--mono); font-size: 11px; }

.facts { padding-top: 28px; padding-bottom: clamp(64px, 8vw, 120px); row-gap: 20px; }
.facts dl { margin: 0; }
.facts dt { color: var(--soft); margin-bottom: 8px; }
.facts dd { margin: 0; font-size: 16px; line-height: 1.45; }
.f-brief { grid-column: 2 / span 4; }
.f-part { grid-column: span 3; }
.f-stack { grid-column: span 2; }
.f-go { grid-column: span 2; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px;
  border: 1px solid var(--ink); border-radius: 999px;
  font-weight: 600; font-size: 15px; text-decoration: none; white-space: nowrap;
  transition: background .2s, color .2s, transform .16s var(--ease);
}
.btn:active, .copy:active, .motion:active { transform: scale(.97); }
.btn:hover { background: var(--ink); color: var(--on-ink); }
.btn.ghost { border-color: var(--chip); }
.btn.ghost:hover { border-color: var(--ink); }
.arr { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
@media (hover: hover) and (pointer: fine) { .btn:hover .arr { transform: translate(2px, -2px); } }

/* About */
.about { padding-top: clamp(88px, 11vw, 168px); padding-bottom: clamp(88px, 11vw, 168px); border-top: 1px solid var(--ink); margin: 0 var(--pad); padding-left: 0; padding-right: 0; }
.about-title { grid-column: span 5; margin: 0; font-size: clamp(44px, 5.4vw, 92px); overflow: hidden; align-self: start; padding-bottom: .04em; }
.about-title span { display: inline-block; }
.about-body { grid-column: 6 / span 7; }
.about-lede { margin: 0 0 56px; font-size: clamp(21px, 2vw, 30px); line-height: 1.3; letter-spacing: -.02em; font-weight: 500; }
.offer { border-top: 1px solid var(--rule); padding-top: 24px; }
.offer p { margin: 0 0 20px; font-size: 18px; line-height: 1.5; color: var(--body); max-width: 60ch; text-wrap: pretty; }
.caps { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 48px 0 0; padding: 0; }
.caps li { border: 1px solid var(--chip); border-radius: 999px; padding: 8px 14px; font-size: 14px; }

/* Footer */
.foot { background: var(--ink); color: var(--on-ink); padding-top: clamp(64px, 8vw, 120px); overflow: hidden; }
.foot a { color: var(--on-ink); }
.foot a:hover { color: #FF8A57; }
.foot :focus-visible { outline-color: #FF8A57; }
.foot-top { row-gap: 32px; align-items: end; }
.foot-say { grid-column: span 6; margin: 0; font-size: clamp(30px, 3.6vw, 58px); line-height: .95; }
.foot-mail { grid-column: 8 / span 5; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.mail { font-size: clamp(26px, 3vw, 46px); font-weight: 600; letter-spacing: -.03em; text-decoration: none; border-bottom: 2px solid var(--accent); line-height: 1.2; padding-top: 6px; padding-bottom: 2px; }
.copy {
  min-height: 44px; min-width: calc(8ch + .32em + 34px); padding: 0 16px; border-radius: 999px;
  border: 1px solid #3A3A38; background: none; color: var(--on-ink); cursor: pointer;
  transition: border-color .2s, background .2s, color .2s, transform .16s var(--ease);
}
.copy:hover { border-color: var(--on-ink); }
.copy span { display: inline-block; }
.copy[data-state="done"] { background: var(--accent); border-color: var(--accent); color: var(--ink); }
.foot-meta { display: flex; flex-wrap: wrap; gap: 8px 32px; margin-top: clamp(56px, 7vw, 96px); color: var(--on-ink-soft); }
.foot-meta { align-items: center; }
.foot-meta a { display: inline-flex; align-items: center; min-height: 44px; color: var(--on-ink-soft); text-decoration: none; }
.foot-meta a:hover { color: var(--on-ink); }
.foot { container-type: inline-size; }
.wordmark {
  margin: clamp(24px, 3vw, 40px) 0 0; padding: 0 var(--pad);
  font-weight: 900; line-height: .78; letter-spacing: -.035em;
  font-size: 20vw;
  font-size: calc((100cqw - 2 * var(--pad)) / 4.62);
  white-space: nowrap; overflow: hidden;
}
.wordmark span { display: inline-block; }

/* Pause switch on each moving strip (all switches share one state) */
.motion {
  position: absolute; z-index: 2; right: calc(var(--pad) + 4px); bottom: 12px;
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px 0 14px;
  border: 1px solid rgba(244, 244, 242, .35); border-radius: 999px;
  background: rgba(12, 12, 12, .9); color: var(--on-ink); cursor: pointer;
  transition: background .2s, transform .16s var(--ease);
}
.motion:hover { background: var(--ink); }
.motion:focus-visible { outline-color: var(--accent); }
.motion svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.motion span { min-width: calc(5ch + .2em); }
.motion path { transform-box: fill-box; transform-origin: center; transition: opacity .15s var(--ease), transform .15s var(--ease); }
.motion .i-play, .motion[aria-pressed="true"] .i-pause { opacity: 0; transform: scale(.6); }
.motion[aria-pressed="true"] .i-play { opacity: 1; transform: none; }

/* Motion */
@keyframes rise { from { transform: translateY(105%); } to { transform: none; } }
@keyframes fade { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fade-only { from { opacity: 0; } to { opacity: 1; } }

.js .rv.case-name span, .js .rv.about-title span { transform: translateY(105%); transition: transform 1s var(--ease); }
.js .rv.case-name.in span, .js .rv.about-title.in span { transform: none; }
.js .rv.case-lede, .js .rv.about-lede { opacity: 0; transform: translateY(18px); transition: opacity .9s .15s var(--ease), transform .9s .15s var(--ease); }
.js .rv.case-lede.in, .js .rv.about-lede.in { opacity: 1; transform: none; }
.js .wordmark.rv span { transform: translateY(100%); transition: transform 1.1s var(--ease); transition-delay: calc(var(--i) * 70ms); }
.js .wordmark.rv.in span { transform: none; }

/* Reduced motion: drop movement, keep short opacity and colour feedback */
@media (prefers-reduced-motion: reduce) {
  .hero-title .w > span { animation: none; }
  .hero-title sup, .status, .intro-text { animation: fade-only .2s both; }
  .row .c-n, .row .c-name, .row .c-what, .row .c-plat, .arr, .btn, .copy, .motion, .motion path { transform: none !important; }
  .preview { scale: none; transition: opacity .2s; }
  .js .rv span, .js .rv { transform: none !important; opacity: 1 !important; transition: none !important; }
}

/* Tablet and phone */
@media (max-width: 900px) {
  .nav-who, .nav-clock { display: none; }
  .brand { grid-column: span 5; }
  .nav-links { grid-column: span 7; }
  .status, .intro-text { grid-column: 1 / -1; }
  .intro-text { order: -1; }
  .hero-title sup { display: none; }
  .c-what, .c-plat { display: none; }
  .c-n { grid-column: span 2; }
  .c-name { grid-column: span 8; }
  .c-yr { grid-column: span 2; }
  .preview { display: none; }
  .case-n, .case-name, .case-lede { grid-column: 1 / -1; }
  .case-n { padding-top: 0; }
  .f-brief, .f-part, .f-stack { grid-column: span 6; }
  .f-brief { grid-column: 1 / -1; }
  .f-go { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-start; }
  .about-title, .about-body { grid-column: 1 / -1; }
  .about-title { margin-bottom: 32px; }
  .foot-say, .foot-mail { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .case-name { font-size: 11.5vw; }
  .f-part, .f-stack { grid-column: 1 / -1; }
  .row { padding: 18px 0; }
  .mail { font-size: 26px; }
}
@media (max-width: 360px) {
  .nav-links { gap: 6px; }
}
