/* animal.studio — page A.
   Structure and motion follow bleibtgleich.dev: an 8 column grid drawn in viewport units, one display size, one small size,
   hairlines, and text that comes out of liquid. The mark, the grain and the typeface (Allo) are ours. */

@font-face { font-family: "Allo"; src: url("../fonts/AlloVariable.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --bg: #111110; --fg: #dddcd6; --fg-rgb: 221, 220, 214; --dim: rgba(var(--fg-rgb), .5); --line: rgba(var(--fg-rgb), .22); --tile: rgba(var(--fg-rgb), .06);
  --cell: 11.25rem; --gap: 1.1111rem; --pad: 1.1111rem; --stroke: max(1px, .035rem);
  --h1: 6.25rem; --h2: 2.7778rem; --p1: .9722rem;
  --out: cubic-bezier(.25, 1, .5, 1); --inout: cubic-bezier(.76, 0, .24, 1);
}
html { font-size: 1vw; background: var(--bg); -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
* { box-sizing: border-box; }
body { margin: 0; color: var(--fg); font-family: "Allo", "Helvetica Neue", Helvetica, Arial, sans-serif; font-weight: 500; font-variation-settings: "ROND" 60;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-x: clip; transition: color .7s var(--inout); }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { color: var(--bg); background: var(--fg); }
::-webkit-scrollbar { display: none; } html { scrollbar-width: none; }

/* the living layer: ground, grain and the mark */
#ink { position: fixed; inset: 0; width: 100%; height: 100%; display: block; z-index: 0; pointer-events: none; }
.no-gl #ink { display: none; }
/* pixel grain over the type, so the words sit in the same surface as the mark */
.grain { position: fixed; inset: -64px; z-index: 90; pointer-events: none; opacity: .055; image-rendering: pixelated; will-change: transform; background-size: 192px 192px; animation: grain .9s steps(6) infinite; }
@keyframes grain { 0% { transform: translate(0, 0); } 20% { transform: translate(-22px, 14px); } 40% { transform: translate(18px, -30px); } 60% { transform: translate(-36px, -8px); } 80% { transform: translate(28px, 26px); } 100% { transform: translate(0, 0); } }

main { position: relative; z-index: 2; }
.h1 { margin: 0; font-size: var(--h1); line-height: .88; letter-spacing: -.05em; font-weight: 520; white-space: nowrap; }
.h2 { font-size: var(--h2); line-height: .8; letter-spacing: -.036em; }
.p1 { margin: 0; font-size: var(--p1); line-height: 1.0714; letter-spacing: -.027em; }
.dim { color: var(--dim); }
.grid { display: grid; grid-template-columns: repeat(8, var(--cell)); column-gap: var(--gap); padding: 0 var(--pad); align-items: start; }
.c1 { grid-column: 1 / -1; } .c2 { grid-column: 2 / -1; } .c3 { grid-column: 3 / -1; } .c4 { grid-column: 4 / -1; } .c5 { grid-column: 5 / -1; } .c6 { grid-column: 6 / -1; } .c7 { grid-column: 7 / -1; }
.row { grid-row: var(--r); }
.stack > * + * { margin-top: 0; }
[data-reveal], [data-pre] { visibility: hidden; }

/* dev grid, toggled by the square in the corner */
.devgrid { position: fixed; inset: 0; z-index: 80; display: none; padding: 0 var(--pad); column-gap: var(--gap); pointer-events: none; justify-content: space-between; }
.devgrid i { display: block; height: 100%; width: 0; background: rgba(var(--fg-rgb), .06); }

/* nav */
nav { position: fixed; inset: 0 0 auto 0; z-index: 95; height: 0; }
.nav-grid { position: absolute; left: var(--pad); top: 1.38rem; width: 1.1111rem; height: 1.1111rem; background: rgba(var(--fg-rgb), .12); visibility: hidden; }
.nav-btn { position: absolute; right: var(--pad); top: var(--pad); padding: .2778rem .5556rem; border-radius: 1.1111rem; background: var(--fg); color: var(--bg); visibility: hidden; transition: background .7s var(--inout), color .7s var(--inout); }
.nav-menu { position: absolute; right: var(--pad); top: 3.6rem; display: none; flex-direction: column; align-items: flex-end; gap: .35rem; }
.menu-link { display: flex; align-items: flex-start; gap: .5rem; padding: .25rem 0; }
.menu-link .ind { font-size: var(--p1); line-height: 1; opacity: .5; padding-top: .1rem; }
.menu-link.small { margin-top: .9rem; }
.roll { position: relative; display: inline-block; overflow: clip; vertical-align: top; padding-bottom: .12em; margin-bottom: -.12em; }
.roll-b { position: absolute; left: 0; top: 0; }
.split-line { display: block; overflow: clip; padding-bottom: .12em; margin-bottom: -.12em; }
.split-char, .split-word { display: inline-block; }

/* scrollbar */
.scrollbar { position: fixed; right: 0; top: 0; bottom: 0; width: .9rem; z-index: 96; padding: .28rem 0; visibility: hidden; opacity: 0; }
.scrollbar .thumb { margin-left: auto; margin-right: .28rem; width: .28rem; height: 1.1111rem; background: rgba(var(--fg-rgb), .28); cursor: grab; touch-action: none; }
.is-dragging, .is-dragging * { cursor: grabbing !important; user-select: none; }

/* ---- intro ---- */
.intro { position: relative; padding-bottom: 12rem; }
.rule { position: absolute; top: 0; bottom: 0; left: calc(var(--pad) + 3 * var(--cell) + 2 * var(--gap)); width: var(--stroke); background: var(--line); clip-path: inset(0 0 100% 0); }
.hero { position: relative; height: 100svh; }
.hero .meta { position: absolute; top: var(--pad); left: calc(var(--pad) + 3 * var(--cell) + 3 * var(--gap)); display: flex; gap: 3rem; }
.hero .role { position: absolute; left: calc(var(--pad) + 2 * var(--cell) + 2 * var(--gap)); bottom: 1.6rem; }
.hero .count { position: absolute; left: var(--pad); bottom: .6rem; }
.hero .mail { position: absolute; left: 50%; top: calc(50% + var(--drop, 12vw) + 1.2rem); transform: translateX(-50%); padding: .6rem 1rem; font-size: max(13px, var(--p1)); color: var(--dim); white-space: nowrap; }
.hero .mail:hover { color: var(--fg); }
.hero .hint { position: absolute; right: calc(var(--pad) + 1.6rem); bottom: 1.6rem; text-align: right; }
.g-name { margin-top: 2rem; }
.g2 { margin-top: .55rem; } .g3 { margin-top: .55rem; }
.off { margin-left: 8.333rem; }
.tiles { margin-top: 7.2rem; display: grid; grid-template-columns: repeat(8, var(--cell)); column-gap: var(--gap); padding: 0 var(--pad); }
.tile { aspect-ratio: 1; background: var(--tile); display: grid; place-items: center; transition: background .7s var(--inout); }
.tile:nth-child(1) { grid-column: 1; } .tile:nth-child(2) { grid-column: 4; } .tile:nth-child(3) { grid-column: 5; } .tile:nth-child(4) { grid-column: 7; } .tile:nth-child(5) { grid-column: 8; }
.tile span { display: block; width: 2.2rem; height: 2.2rem; border-radius: 50%; border: .07rem solid var(--c); }
.lede { margin-top: 1.2rem; max-width: 24rem; }
.say { margin-top: 8.4rem; row-gap: 0; }
.fine { margin-top: 15rem; }

/* ---- work ---- */
.work { position: relative; padding: 12rem 0 14rem; }
.work-head { display: flex; justify-content: center; height: 5.5rem; }
.work-head .inner { display: flex; justify-content: space-between; gap: 2.2rem; align-items: baseline; }
.work-head .go { display: none; }
.globe { position: relative; width: 50.6rem; height: 50.6rem; margin: 6rem auto 0; perspective: 150rem; touch-action: pan-y; cursor: grab; }
.globe-inner { position: absolute; inset: 0; transform-style: preserve-3d; will-change: transform; }
.card { position: absolute; left: 50%; top: 50%; width: var(--w, 8rem); height: var(--h, 5.4rem); margin: calc(var(--h, 5.4rem) / -2) 0 0 calc(var(--w, 8rem) / -2); background: #000; overflow: hidden; backface-visibility: visible; will-change: transform, opacity; }
.card img, .card video { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }

/* ---- list ---- */
.list { padding: 4rem 0 12rem; }
.list-head { row-gap: 0; }
.rows { margin-top: 8rem; }
.group { display: grid; grid-template-columns: repeat(8, var(--cell)); column-gap: var(--gap); padding: 0 var(--pad); margin-top: 1.6rem; }
.item { grid-column: 2 / -1; display: grid; grid-template-columns: repeat(7, var(--cell)); column-gap: var(--gap); position: relative; padding: .5rem 0 .45rem; border-top: var(--stroke) solid var(--line); cursor: default; }
.item > .p1:nth-child(1) { grid-column: 1; } .item > .p1:nth-child(2) { grid-column: 2 / span 2; } .item > .p1:nth-child(3) { grid-column: 4 / span 2; } .item > .p1:nth-child(4) { grid-column: 6 / span 2; }
.item .peek { position: absolute; right: 0; bottom: 0; width: var(--cell); aspect-ratio: 16 / 10; overflow: hidden; background: #000; z-index: 3; pointer-events: none; clip-path: inset(100% 0 0 0); transform: scale(.9); transform-origin: 50% 100%; }
.item .peek.tall { aspect-ratio: 9 / 14; }
.item .peek img, .item .peek video { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- line ---- */
.line { padding: 6rem 0 0; }
.clock { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr; align-items: center; padding: 6rem calc(var(--pad) + var(--cell)) 6rem; }
.clock .h1 { text-align: center; }
.clock .frame { width: 13.2rem; height: 18.4rem; background: #000; overflow: hidden; }
.clock .frame video { width: 100%; height: 100%; object-fit: cover; display: block; }
.right { justify-self: end; text-align: right; }

/* ---- contact + foot ---- */
.contact { position: relative; padding: 1rem 0 0; }
.contact .info { margin-top: -10.5rem; }
.contact .info .p1 + .p1 { margin-top: 1.5rem; }
.dial { margin: 9rem auto 0; display: flex; justify-content: center; gap: .55rem; position: relative; }
.dial button { width: 4.4rem; height: 4.4rem; border-radius: 50%; border: var(--stroke) solid var(--line); display: grid; place-items: center; transition: border-color .4s var(--out), background .4s var(--out), color .4s var(--out); }
.dial button:hover { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.dial-say { height: 1.2rem; margin-top: 1.3rem; text-align: center; position: relative; }
.dial-say .p1 { position: absolute; left: 50%; top: 0; transform: translateX(-50%); white-space: nowrap; }
.foot { position: relative; height: 26rem; }
.foot .l, .foot .r { position: absolute; bottom: 1.1rem; }
.foot .l { left: var(--pad); } .foot .r { right: var(--pad); }

/* still fallback when WebGL is missing */
.still-mark { display: none; }
.no-gl .still-mark { display: block; position: absolute; left: 50%; top: 50%; width: 72vw; transform: translate(-50%, -50%); }

@media (max-width: 991px) {
  html { font-size: 2.5445vw; }
  :root { --cell: calc((100vw - 2 * var(--pad) - 3 * var(--gap)) / 4); --gap: .8rem; --pad: .8rem; --h1: 5.4rem; --p1: 1.35rem; --h2: 3rem; }
  .grid, .tiles, .group { grid-template-columns: repeat(4, var(--cell)); }
  .c2, .c3 { grid-column: 1 / -1; } .c4, .c5, .c6, .c7 { grid-column: 2 / -1; }
  .h1 { white-space: normal; }
  .rule { left: calc(var(--pad) + var(--cell) + var(--gap) / 2); }
  .hero .meta { left: calc(var(--pad) + var(--cell) + var(--gap)); flex-direction: column; gap: .4rem; }
  .hero .role { left: var(--pad); bottom: 7.4rem; } .hero .hint { display: none; }
  .off { margin-left: 3rem; }
  .tile:nth-child(1) { grid-column: 1; } .tile:nth-child(2) { grid-column: 2; } .tile:nth-child(3) { grid-column: 3; } .tile:nth-child(4) { grid-column: 4; } .tile:nth-child(5) { display: none; }
  .tile span { width: 1.6rem; height: 1.6rem; }
  .lede { max-width: none; padding-right: 1rem; }
  .work-head { height: auto; } .work-head .inner { flex-direction: column; align-items: center; gap: 0; width: auto !important; }
  .globe { width: 36rem; height: 36rem; margin-top: 3rem; }
  .item { grid-column: 1 / -1; grid-template-columns: 3.4rem 1fr 1fr; } .item > .p1:nth-child(1) { grid-column: 1; } .item > .p1:nth-child(2) { grid-column: 2; } .item > .p1:nth-child(3) { grid-column: 3; } .item > .p1:nth-child(4) { display: none; }
  .item .peek { display: none; }
  .clock { padding: 4rem var(--pad); } .clock .frame { width: 9rem; height: 12.6rem; } .clock .h1 { font-size: 3.4rem; }
  .contact .info { margin-top: 3rem; }
  .dial button { width: 6rem; height: 6rem; }
  .nav-grid { width: 1.6rem; height: 1.6rem; top: .9rem; } .nav-btn { padding: .45rem .9rem; border-radius: 2rem; } .nav-menu { top: 4.4rem; }
  .scrollbar { display: none; }
  .foot { height: 24rem; }
}
@media (prefers-reduced-motion: reduce) { .grain { animation: none; } }

/* ---- additions ---- */
#goo-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.goo-line { display: block; }
.tile { cursor: pointer; }
.tile span { position: relative; background: var(--c); border-color: rgba(var(--fg-rgb), .35); transition: transform .8s var(--out); }
.tile span::after { content: ""; position: absolute; left: 50%; top: 50%; width: .5rem; height: .5rem; margin: -.25rem 0 0 -.25rem; border-radius: 50%; background: var(--d); }
.tile:hover span { transform: scale(1.18); }
.contact .info { max-width: 15rem; }
.contact .info a { border-bottom: var(--stroke) solid var(--line); }
.no-gl .still-mark { height: 14.4vw; background: var(--fg); -webkit-mask: url("../brand/animal.studio_web-currentColor.svg") center / contain no-repeat; mask: url("../brand/animal.studio_web-currentColor.svg") center / contain no-repeat; }
.reel { position: fixed; inset: 0; z-index: 97; background: #000; clip-path: inset(100% 0 0 0); visibility: hidden; }
.reel video { width: 100%; height: 100%; object-fit: contain; display: block; }
.reel .x { position: absolute; right: var(--pad); top: var(--pad); padding: .2778rem .5556rem; border-radius: 1.1111rem; background: #dddcd6; color: #111110; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.item:hover .p1 { color: var(--fg); }
.globe.is-drag { cursor: grabbing; }
@media (max-width: 991px) { .contact .info { max-width: none; } .reel .x { padding: .45rem .9rem; border-radius: 2rem; } .tile span::after { width: .4rem; height: .4rem; margin: -.2rem 0 0 -.2rem; } }
