/* Paria portfolio: black, white, one loud move (the work list). */

:root {
  --bg: #000;
  --fg: #fff;
  --dim: #8a8a8a;
  --line: #2b2b2b;
  --panel: #111;
  --pad: clamp(20px, 5vw, 120px);
  --max: 1200px;
  --soft: #d8d8d8;
  --display: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --body: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--body);
  font-size: clamp(16px, 1.15vw, 18px);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; }

:focus-visible { outline: 2px solid var(--fg); outline-offset: 4px; }

.wrap { width: 100%; max-width: calc(var(--max) + var(--pad) * 2); margin-inline: auto; padding-inline: var(--pad); }

/* ---------- top bar ---------- */
.bar {
  position: sticky; top: 0; z-index: 20;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.bar .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.mark { font-family: var(--display); font-weight: 800; font-size: 28px; text-decoration: none; letter-spacing: -0.03em; }
.bar nav { display: flex; gap: clamp(16px, 3vw, 40px); }
.bar nav a { text-decoration: none; font-weight: 500; color: var(--dim); transition: color .2s; }
.bar nav a:hover { color: var(--fg); }

/* ---------- hero ---------- */
.hero { padding-block: clamp(56px, 12vh, 160px) clamp(56px, 10vh, 120px); }
.hero h1 {
  margin: 0;
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(64px, 15.5vw, 260px);
  line-height: 0.86;
  letter-spacing: -0.055em;
}
.hero h1 > span { display: block; }
.hero p {
  max-width: 34ch;
  margin: clamp(32px, 6vh, 72px) 0 0;
  font-size: clamp(20px, 2vw, 30px);
  line-height: 1.3;
  letter-spacing: -0.01em;
}

/* the single orchestrated load moment */
@media (prefers-reduced-motion: no-preference) {
  .hero h1 > span { clip-path: inset(0 0 100% 0); transform: translateY(24px); animation: rise .9s .35s cubic-bezier(.2,.7,.1,1) forwards; }
  .hero h1 > span:nth-child(2) { animation-delay: .47s; }
  .hero p { opacity: 0; animation: fade .8s .9s ease forwards; }
}
@keyframes rise { to { clip-path: inset(-30% -6% -30% -6%); transform: none; } }
@keyframes fade { to { opacity: 1; } }

/* ---------- work list ---------- */
.work { border-top: 1px solid var(--line); }
.work-head { padding-block: 28px; display: flex; justify-content: space-between; color: var(--dim); }

.rows { list-style: none; margin: 0; padding: 0; }
.row { border-top: 1px solid var(--line); }
.row:last-child { border-bottom: 1px solid var(--line); }

.row a {
  display: grid;
  grid-template-columns: clamp(48px, 7vw, 110px) 1fr auto;
  align-items: baseline;
  gap: 16px;
  padding: clamp(22px, 3.2vw, 44px) max(var(--pad), calc((100vw - var(--max)) / 2));
  text-decoration: none;
  transition: background .18s, color .18s;
}
.row .n { color: var(--dim); font-weight: 500; transition: color .18s; }
.row .t {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(30px, 5.6vw, 92px);
  line-height: 0.98;
  letter-spacing: -0.04em;
  text-wrap: balance;
}
.row .m { text-align: right; color: var(--dim); font-weight: 500; white-space: nowrap; transition: color .18s; }

.row a:hover, .row a:focus-visible { background: var(--fg); color: var(--bg); outline-offset: -4px; }
.row a:hover .n, .row a:hover .m, .row a:focus-visible .n, .row a:focus-visible .m { color: #555; }

.row.soon a { cursor: default; }
.row.soon .m::after { content: "  (case study coming)"; }

/* floating preview that follows the cursor on desktop */
.peek {
  position: fixed; left: 0; top: 0; z-index: 30;
  width: min(34vw, 460px); aspect-ratio: 4 / 3;
  background: var(--panel);
  pointer-events: none;
  opacity: 0; transform: translate3d(0,0,0) scale(.96);
  transition: opacity .16s;
  overflow: hidden;
}
.peek.on { opacity: 1; }
.peek img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.05); }
@media (hover: none), (max-width: 800px) { .peek { display: none; } }

/* ---------- about + contact ---------- */
.about { padding-block: clamp(72px, 14vh, 180px); }
.about-grid { display: grid; grid-template-columns: 1fr 2fr; gap: clamp(24px, 6vw, 96px); }
.about h2, .case h2 {
  margin: 0;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(32px, 4vw, 56px);
  line-height: 1;
  letter-spacing: -0.035em;
}
.about p { margin: 0 0 1.2em; max-width: 52ch; font-size: clamp(18px, 1.6vw, 24px); line-height: 1.4; }

.contact { border-top: 1px solid var(--line); padding-block: clamp(56px, 10vh, 120px) 40px; }
.contact a.big {
  display: inline-block;
  font-family: var(--display); font-weight: 800;
  font-size: clamp(26px, 6vw, 96px);
  line-height: 1; letter-spacing: -0.05em;
  text-decoration: none;
  border-bottom: 3px solid var(--fg);
  padding-bottom: .06em;
  overflow-wrap: anywhere;
}
.contact a.big:hover { background: var(--fg); color: var(--bg); }
.links { display: flex; gap: 28px; margin-top: 40px; flex-wrap: wrap; }
.links a { color: var(--dim); text-decoration: none; font-weight: 500; }
.links a:hover { color: var(--fg); }
.foot { margin-top: 72px; color: var(--dim); font-size: 14px; }

/* ---------- case study ---------- */
.case-hero { padding-block: clamp(48px, 9vh, 112px) clamp(40px, 7vh, 80px); }
.case-hero .idx { font-family: var(--display); font-weight: 700; font-size: clamp(24px, 3vw, 40px); color: var(--dim); margin: 0 0 16px; }
.case-hero h1 {
  margin: 0;
  font-family: var(--display); font-weight: 800;
  font-size: clamp(56px, 12vw, 200px);
  line-height: 0.88; letter-spacing: -0.055em;
}
.case-hero .lede { max-width: 40ch; margin: clamp(24px, 4vh, 48px) 0 0; font-size: clamp(20px, 2vw, 30px); line-height: 1.3; }

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 24px; margin: clamp(32px, 6vh, 64px) 0 0; padding-top: 24px; border-top: 1px solid var(--line); }
.facts dt { color: var(--dim); font-size: 14px; }
.facts dd { margin: 4px 0 0; font-weight: 500; }

.case section.sec { display: grid; grid-template-columns: 1fr 2fr; gap: clamp(24px, 6vw, 96px); padding-block: clamp(48px, 9vh, 112px); border-top: 1px solid var(--line); }
.case section.sec > .lead { align-self: start; position: sticky; top: 96px; }
.case section.sec .body > * + * { margin-top: 1.4em; }
.case .body p { margin: 0; max-width: 62ch; }
.case .body h3 { margin: 0; font-family: var(--display); font-weight: 700; font-size: clamp(22px, 2vw, 30px); letter-spacing: -0.02em; line-height: 1.1; }
.case .full { padding-block: 0 clamp(48px, 9vh, 112px); }

/* shots: real image on top, placeholder underneath until you add the file */
.shot { position: relative; margin: 0; background: var(--panel); aspect-ratio: var(--r, 16/9); overflow: hidden; }
.shot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.shot::after {
  content: attr(data-file);
  position: absolute; inset: 0; display: grid; place-items: center;
  color: #5a5a5a; font-size: 14px; text-align: center; padding: 16px;
}
.shot.has::after { display: none; }

/* big numbers: only where the number is the story */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 32px; }
.stat b { display: block; font-family: var(--display); font-weight: 800; font-size: clamp(64px, 9vw, 136px); line-height: .9; letter-spacing: -0.06em; }
.stat span { color: var(--dim); }

/* insights as statements */
.insight { border-top: 1px solid var(--line); padding-block: 24px; }
.insight small { display: block; color: var(--dim); margin-bottom: 8px; }
.insight p { font-family: var(--display); font-weight: 600; font-size: clamp(22px, 2.6vw, 38px); line-height: 1.12; letter-spacing: -0.025em; max-width: 28ch; }

.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 32px; }
.cols ul, .plain { margin: 8px 0 0; padding: 0; list-style: none; color: var(--soft); }
.cols li, .plain li { padding: 8px 0; border-bottom: 1px solid var(--line); }

.next { display: block; padding: clamp(48px, 10vh, 120px) max(var(--pad), calc((100vw - var(--max)) / 2)); border-top: 1px solid var(--line); text-decoration: none; }
.next small { color: var(--dim); display: block; margin-bottom: 8px; }
.next strong { font-family: var(--display); font-weight: 800; font-size: clamp(40px, 8vw, 120px); line-height: .95; letter-spacing: -0.05em; }
.next:hover { background: var(--fg); color: var(--bg); }
.next:hover small { color: #555; }

/* ---------- small screens ---------- */
@media (max-width: 800px) {
  .row a { grid-template-columns: 36px 1fr; }
  .row .m { grid-column: 2; text-align: left; white-space: normal; }
  .about-grid, .case section.sec { grid-template-columns: 1fr; }
  .case section.sec > .lead { position: static; }
}

/* image groups */
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
@media (max-width: 800px) { .pair, .trio { grid-template-columns: 1fr; } }
.lede.light, .hero p { font-weight: 300; }
.case-hero .lede { text-wrap: pretty; }


/* ---------- interactive name ---------- */
.hero h1 .ch {
  display: inline-block; white-space: pre;
  transition: transform .18s ease-out;
  transform: translateY(calc(var(--p, 0) * -0.07em)) skewX(calc(var(--p, 0) * -12deg));
}
.hero h1 .ch.hot { color: transparent; -webkit-text-stroke: 0.02em var(--fg); }

/* ---------- custom cursor ---------- */
.cursor { display: none; }
html.has-cursor, html.has-cursor * { cursor: none !important; }
html.has-cursor .cursor {
  display: block;
  position: fixed; left: 0; top: 0; z-index: 200;
  width: 14px; height: 14px; margin: -7px 0 0 -7px;
  border-radius: 50%; background: #fff; mix-blend-mode: difference;
  pointer-events: none;
  transition: width .25s, height .25s, margin .25s;
}
html.has-cursor .cursor.link { width: 64px; height: 64px; margin: -32px 0 0 -32px; }

/* ---------- page curtain ---------- */
.curtain { position: fixed; inset: 0; z-index: 100; background: var(--fg); pointer-events: none; transform: translateY(-100%); }
@media (prefers-reduced-motion: no-preference) {
  .curtain { transform: translateY(0); animation: uncover .6s .08s cubic-bezier(.7, 0, .2, 1) forwards; }
  .curtain.leave { animation: cover .45s cubic-bezier(.7, 0, .2, 1) forwards; pointer-events: auto; }
}
@keyframes uncover { to { transform: translateY(-100%); } }
@keyframes cover { from { transform: translateY(100%); } to { transform: translateY(0); } }
