/* Duty Calls: a real roll on a real wall. Scroll to pull; the camera moves in, the paper comes down. */
:root {
  --wall: #E9E5E1;
  --printed: #262522;
}
body.on-pull { background: var(--wall); }

/* header sits on the wall */
.topbar {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px var(--gutter); color: var(--ink);
  transition: background .25s, box-shadow .25s;
}
.topbar.solid { background: rgba(233, 229, 225, .92); backdrop-filter: blur(8px); box-shadow: 0 1px 0 rgba(0,0,0,.08); }
.topbar .logo { display: block; line-height: 0; }
.topbar .logo img { height: 52px; width: auto; filter: drop-shadow(0 2px 3px rgba(60, 45, 30, .18)); }
.nav { display: flex; gap: clamp(14px, 3vw, 36px); }
.nav a { font: 700 .76rem var(--mono); text-transform: uppercase; letter-spacing: .14em; text-decoration: none; }
.nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.pill {
  font: 800 .82rem var(--body); text-transform: uppercase; letter-spacing: .05em; text-decoration: none;
  background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px;
}
.pill:hover { background: #333; }

/* ---------- the pull ---------- */
.pull { position: relative; height: 900vh; padding: 0; background: var(--wall); }
.stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; }
.scene { position: absolute; left: 0; top: 0; width: 1552px; height: 882px; transform-origin: 0 0; }
.scene > * { position: absolute; }
.wallimg { left: -700px; top: -600px; width: 2952px; height: 2900px; max-width: none; }
.stickers { left: 0; top: 0; width: 1552px; height: 882px; }
/* the cast as vinyl stickers on the wall: slightly lifted, a little crooked */
.stk { position: absolute; height: auto; max-width: none; transform: rotate(var(--r, 0deg));
  filter: drop-shadow(0 1.5px 1px rgba(50, 38, 25, .28)) drop-shadow(0 5px 9px rgba(50, 38, 25, .14)); }
.stk-toilet  { left: 105px;  top: 410px; width: 205px; --r: -8deg; }
.stk-minion2 { left: 250px;  top: 700px; width: 120px; --r: 12deg; }
.stk-tube    { left: 1290px; top: 300px; width: 175px; --r: 9deg; }
.stk-minion  { left: 1330px; top: 610px; width: 150px; --r: -11deg; }
.stk-rollie { --r: -7deg; width: 200px; left: 300px; top: 900px; }
.pull.phone .stk-rollie { display: none; }
/* bathroom-wall graffiti, right of the paper: marker on paint */
.graffiti { --gw: 220px; left: 1120px; top: 900px; width: var(--gw); color: #2b2a33; text-decoration: none; text-align: center;
  font: 400 calc(var(--gw) * .118)/1.08 "Permanent Marker", "Comic Sans MS", cursive; transform: rotate(-6deg); mix-blend-mode: multiply; opacity: .86;
  -webkit-mask: url("/tex/ink-mask.webp") 0 0 / 140px auto; mask: url("/tex/ink-mask.webp") 0 0 / 140px auto; }
.graffiti span { display: block; }
.graffiti .g2 { font-size: 1.12em; margin-top: .35em; transform: rotate(2deg); }
.graffiti .g3 { display: block; width: 86%; margin: .05em auto 0; }
.graffiti:hover { color: #000; }
.pull.phone .graffiti { display: none; }
.pull.phone .stk-toilet  { left: 330px;  top: 860px;  width: 165px; }
.pull.phone .stk-minion2 { left: 380px;  top: 1110px; width: 110px; }
.pull.phone .stk-tube    { left: 1110px; top: 830px;  width: 160px; }
.pull.phone .stk-minion  { left: 1140px; top: 1080px; width: 130px; }
.holder  { left: 290px; top: 352px; width: 1010px; height: 530px; max-width: none; }

/* the hanging sheet: static frame (light + shadow stay put), moving paper inside */
.sheet {
  --D: 0px;
  left: 507px; top: 752px; width: 588px; height: 1700px; overflow: hidden;
  background: #f4f1ec;
  box-shadow: -18px 4px 46px -4px rgba(75, 58, 40, .40), 18px 4px 46px -4px rgba(75, 58, 40, .40);
}
.ptex {
  position: absolute; inset: 0;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='600'%3E%3Crect x='0' y='0' width='7' height='1.6' fill='%23000' fill-opacity='.16'/%3E%3Crect x='0' y='1.6' width='12' height='1.2' fill='%23fff' fill-opacity='.5'/%3E%3C/svg%3E"),
    url("/tex/rollie-emboss.webp");
  background-size: 12px 470px, var(--tw, 200px) auto;
  background-position: 0 calc(var(--D) + 280px), var(--tx, 0px) var(--D);
}
.copy { position: absolute; left: 0; top: 0; width: 100%; transform: translateY(var(--D)); mix-blend-mode: multiply; color: #1d1c1a; }
/* printed: the ink soaks into the valleys of the paper and skips the raised fibres and the emboss.
   The mask is built from the same texture and lined up with it per block (see app.js). */
.copy .blk {
  text-shadow: 0 0 .9px rgba(29, 28, 26, .55);
  -webkit-mask-image: url("/tex/ink-mask.webp"); mask-image: url("/tex/ink-mask.webp");
  -webkit-mask-size: var(--tw, 200px) auto; mask-size: var(--tw, 200px) auto;
  -webkit-mask-repeat: repeat; mask-repeat: repeat;
}
.copy .ink-art, .copy .ink-aside img { opacity: .82; }
.plight { position: absolute; left: 0; top: 0; width: 100%; height: 1700px; pointer-events: none;
  background: url("/tex/sheet-light-over.webp") 0 0 / 100% 1700px no-repeat; mix-blend-mode: multiply; }

/* over: the sheet runs off the front of the roll, full width, no seam */
.rollc { left: 507px; top: 401px; width: 588px; height: 358px; border-radius: 10px 10px 0 0; }

/* under: the sheet comes from behind, narrower, in the roll's shadow */
.pull.under .sheet { left: 511px; width: 579px; --tx: -4px;
  box-shadow: -10px 4px 16px -6px rgba(60, 45, 30, .42), 10px 4px 16px -6px rgba(60, 45, 30, .42); }
.pull.under .plight { background-image: url("/tex/sheet-light.webp"); }
.pull.under .plight::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 70px;
  background: linear-gradient(rgba(60, 45, 30, .45), rgba(60, 45, 30, 0)); }
.pull.under .rollc { border-radius: 10px 10px 5px 5px; box-shadow: 0 8px 12px -6px rgba(50, 38, 25, .45); }

/* printed copy, in scene pixels (the scene is scaled as a whole) */
.blk { position: absolute; left: 0; width: 100%; padding: 0 58px; text-align: center; }
.blk p, .blk h2 { margin: 0; }
.ink-kicker { font: 800 15px/1 var(--body); text-transform: uppercase; letter-spacing: .24em; margin-bottom: 18px !important; }
.b-kick .ink-kicker { margin: 0 !important; }
.ink-big { font: 400 46px/1.04 var(--body); text-transform: uppercase; letter-spacing: .01em; }
.ink-big b { font-weight: 900; }
.ink-h { font: 900 50px/.98 var(--body); text-transform: uppercase; letter-spacing: 0; margin-bottom: 18px !important; }
.ink-p { font: 500 21px/1.42 var(--body); max-width: 25em; margin: 0 auto 4px !important; }
.ink-quote { font: 800 30px/1.18 var(--body); }
.ink-sig { font: 700 13px/1 var(--mono); text-transform: uppercase; letter-spacing: .2em; margin-top: 14px !important; opacity: .8; }
.ink-art { width: 150px; height: auto; margin: 0 auto 10px; }
.ink-sizes { display: flex; justify-content: center; gap: 18px; margin: 4px 0 10px !important; }
.ink-sizes span { font: 900 54px/1 var(--body); width: 80px; height: 80px; font-size: 44px; display: grid; place-items: center; border: 4px solid currentColor; border-radius: 50%; }
.ink-aside { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 18px !important; font: 700 18px/1.3 var(--body); font-style: italic; }
.ink-aside img { width: 64px; height: 64px; flex: none; }
.ink-checks { list-style: none; padding: 0; margin: 6px auto 0; display: inline-grid; gap: 16px; text-align: left; }
.ink-checks li { font: 800 25px/1.25 var(--body); display: flex; align-items: center; gap: 16px; }
.ink-checks li::before { content: ""; flex: none; width: 34px; height: 34px; border: 3.5px solid currentColor; border-radius: 6px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M4 12.5l5 5L20 6' fill='none' stroke='%231d1c1a' stroke-width='3.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 80% no-repeat; }
.btn-shop { margin-top: 22px; font-size: 19px; padding: 16px 30px; background: #2a2825; }
.ink-fine { font: 12px/1.5 var(--mono); margin-top: 12px !important; opacity: .8; }

.btn-ink {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; cursor: pointer;
  background: #1e1d1b; color: #fff; border: 0; border-radius: 999px; padding: 14px 24px;
  font: 700 1rem var(--body);
}
.btn-ink:hover { background: #000; }
.paper-form { justify-content: center; margin: 6px auto 0; max-width: 400px; gap: 10px; }
.paper-form input[type="email"] { flex: 1 1 100%; border: 2.5px solid rgba(38,36,33,.86); background: transparent; border-radius: 999px; padding: 13px 18px; font: 500 18px var(--body); color: var(--ink); }
.paper-form .btn-ink { width: 100%; font-size: 18px; padding: 15px 24px; background: #2a2825; }
.paper-form .form-msg { font-size: 14px; }
.paper-form .form-msg.ok { color: var(--accent-2); }

/* phone: bigger body type so it reads at the smaller zoom */
.pull.phone .ink-p { font-size: 27px; }
.pull.phone .ink-kicker { font-size: 19px; }
.pull.phone .ink-sig, .pull.phone .ink-fine { font-size: 17px; }
.pull.phone .ink-checks li { font-size: 29px; }
.pull.phone .btn-shop { font-size: 24px; }
.pull.phone .paper-form input[type="email"], .pull.phone .paper-form .btn-ink { font-size: 24px; }

/* screen-space UI over the scene */
.hero-ui { position: absolute; inset: 0; pointer-events: none; }
.headline {
  position: absolute; left: 0; right: 0; top: 0; padding: 0 var(--gutter); text-align: center;
  font: 900 120px/.9 var(--body); white-space: nowrap; text-transform: uppercase; letter-spacing: -.012em;
  color: #262422; mix-blend-mode: multiply;
}
.headline .dot { color: var(--accent); }
.pick { position: absolute; text-align: center; pointer-events: auto; }
.toggle { display: inline-flex; background: #fff; border-radius: 999px; padding: 4px; box-shadow: 0 6px 18px rgba(60,50,40,.18), inset 0 0 0 2px var(--ink); }
.toggle button { font: 800 .82rem var(--body); text-transform: uppercase; letter-spacing: .1em; border: 0; background: transparent; color: var(--ink); padding: 9px 16px; border-radius: 999px; cursor: pointer; }
.toggle button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.pick-note { max-width: 36ch; margin: 8px auto 0; line-height: 1.5; font: 700 .68rem var(--mono); text-transform: uppercase; letter-spacing: .18em; color: #57534d; }
.cue { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); margin: 0; font: 700 .7rem var(--mono); text-transform: uppercase; letter-spacing: .2em; color: #4a4640; display: grid; justify-items: center; gap: 6px; }
.cue span { width: 12px; height: 12px; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: rotate(45deg); animation: nudge 1.5s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateY(5px) rotate(45deg); } }

.join-anchor { position: absolute; left: 0; bottom: 0; height: 100vh; width: 1px; pointer-events: none; }

/* the last sheet tears off: the cast section is that torn sheet, lying over the end of the pull */
.cast-wrap { position: relative; z-index: 2; margin-top: -120px; filter: drop-shadow(0 -8px 14px rgba(60, 45, 30, .28)); }
.on-pull .cast {
  position: relative; border-top: 0; padding-top: clamp(150px, 16vw, 210px);
  background: #f4f2ef url("/tex/rollie-emboss.webp") 0 0 / 200px auto;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='44' preserveAspectRatio='none'%3E%3Cpath d='M0 44 L0 24 L11.9 29.3 L27.2 29.2 L32.5 22.1 L44.7 6.7 L52.4 24.1 L57.5 15.6 L72.6 29.9 L86.4 13.6 L92.8 10.0 L100.1 15.6 L114.7 17.5 L125.6 27.6 L141.0 28.0 L155.8 17.8 L162.6 5.0 L174.2 10.1 L183.0 18.1 L193.3 18.2 L206.0 11.5 L211.3 29.5 L216.5 30.5 L227.8 3.8 L243.3 15.1 L258.6 34.5 L267.5 23.6 L273.6 29.5 L288.1 11.0 L294.1 18.9 L309.2 18.8 L320.2 18.1 L327.2 8.9 L343.1 11.9 L354.0 20.6 L365.5 31.5 L375.2 11.4 L380.5 22.8 L387.0 29.0 L398.9 6.3 L405.5 32.0 L415.5 36.0 L431.3 21.8 L444.3 22.5 L453.7 13.8 L469.6 35.0 L480.1 4.7 L493.7 32.6 L507.3 30.1 L519.6 29.8 L532.4 17.3 L545.9 28.0 L561.3 26.9 L566.4 24.2 L578.8 22.0 L590.9 30.7 L603.0 29.2 L611.8 31.9 L624.4 35.4 L635.1 23.8 L649.3 34.4 L661.9 28.7 L668.8 30.3 L681.1 20.9 L694.6 26.6 L699.9 14.2 L712.1 15.7 L724.0 11.1 L731.5 5.2 L738.5 6.7 L747.7 25.9 L755.3 6.1 L763.4 10.3 L772.5 10.9 L778.5 24.2 L789.9 34.9 L799.5 31.1 L808.6 13.7 L819.8 34.9 L831.5 19.1 L836.5 12.8 L848.3 13.7 L863.1 19.8 L870.6 17.6 L879.7 35.0 L891.3 16.8 L901.8 20.8 L917.6 22.8 L927.8 13.2 L937.7 17.6 L951.8 10.3 L959.8 34.3 L967.5 17.0 L983.4 17.6 L993.6 26.8 L1006.8 13.1 L1015.1 23.9 L1023.4 23.8 L1032.3 29.4 L1037.7 16.6 L1052.8 33.1 L1058.0 30.2 L1069.3 28.4 L1079.6 33.7 L1088.9 32.1 L1097.2 10.4 L1109.8 21.3 L1123.4 6.8 L1134.5 22.9 L1141.1 25.2 L1146.9 16.0 L1160.6 9.2 L1176.4 36.0 L1181.9 31.9 L1188 34.8 L1200 24 L1200 44 Z' fill='%23000'/%3E%3C/svg%3E") top left / 1200px 44px repeat-x, linear-gradient(#000, #000) 0 43px / 100% calc(100% - 43px) no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='44' preserveAspectRatio='none'%3E%3Cpath d='M0 44 L0 24 L11.9 29.3 L27.2 29.2 L32.5 22.1 L44.7 6.7 L52.4 24.1 L57.5 15.6 L72.6 29.9 L86.4 13.6 L92.8 10.0 L100.1 15.6 L114.7 17.5 L125.6 27.6 L141.0 28.0 L155.8 17.8 L162.6 5.0 L174.2 10.1 L183.0 18.1 L193.3 18.2 L206.0 11.5 L211.3 29.5 L216.5 30.5 L227.8 3.8 L243.3 15.1 L258.6 34.5 L267.5 23.6 L273.6 29.5 L288.1 11.0 L294.1 18.9 L309.2 18.8 L320.2 18.1 L327.2 8.9 L343.1 11.9 L354.0 20.6 L365.5 31.5 L375.2 11.4 L380.5 22.8 L387.0 29.0 L398.9 6.3 L405.5 32.0 L415.5 36.0 L431.3 21.8 L444.3 22.5 L453.7 13.8 L469.6 35.0 L480.1 4.7 L493.7 32.6 L507.3 30.1 L519.6 29.8 L532.4 17.3 L545.9 28.0 L561.3 26.9 L566.4 24.2 L578.8 22.0 L590.9 30.7 L603.0 29.2 L611.8 31.9 L624.4 35.4 L635.1 23.8 L649.3 34.4 L661.9 28.7 L668.8 30.3 L681.1 20.9 L694.6 26.6 L699.9 14.2 L712.1 15.7 L724.0 11.1 L731.5 5.2 L738.5 6.7 L747.7 25.9 L755.3 6.1 L763.4 10.3 L772.5 10.9 L778.5 24.2 L789.9 34.9 L799.5 31.1 L808.6 13.7 L819.8 34.9 L831.5 19.1 L836.5 12.8 L848.3 13.7 L863.1 19.8 L870.6 17.6 L879.7 35.0 L891.3 16.8 L901.8 20.8 L917.6 22.8 L927.8 13.2 L937.7 17.6 L951.8 10.3 L959.8 34.3 L967.5 17.0 L983.4 17.6 L993.6 26.8 L1006.8 13.1 L1015.1 23.9 L1023.4 23.8 L1032.3 29.4 L1037.7 16.6 L1052.8 33.1 L1058.0 30.2 L1069.3 28.4 L1079.6 33.7 L1088.9 32.1 L1097.2 10.4 L1109.8 21.3 L1123.4 6.8 L1134.5 22.9 L1141.1 25.2 L1146.9 16.0 L1160.6 9.2 L1176.4 36.0 L1181.9 31.9 L1188 34.8 L1200 24 L1200 44 Z' fill='%23000'/%3E%3C/svg%3E") top left / 1200px 44px repeat-x, linear-gradient(#000, #000) 0 43px / 100% calc(100% - 43px) no-repeat;
}
.on-pull .cast .label, .on-pull .cast h2 { mix-blend-mode: multiply; }
.tear-note { position: absolute; left: 50%; top: 64px; transform: translateX(-50%); margin: 0; font: 700 .72rem var(--mono); letter-spacing: .2em; text-transform: uppercase; color: #5a554d; width: max-content; max-width: calc(100% - 32px); text-align: center; line-height: 1.6; }
.peek { position: absolute; right: clamp(16px, 8vw, 140px); top: -96px; width: clamp(120px, 14vw, 190px); z-index: 3; transform-origin: 50% 100%;
  transform: translateY(70px) rotate(-8deg); opacity: 0; transition: transform .7s cubic-bezier(.2, 1.4, .4, 1), opacity .3s; }
.peek.in { transform: translateY(0) rotate(-4deg); opacity: 1; animation: wave 2.4s 1s ease-in-out infinite; }
@keyframes wave { 50% { transform: translateY(-4px) rotate(3deg); } }

@media (max-width: 760px) {
  .topbar .nav { display: none; }
  .topbar .logo img { height: 42px; }
  .pill { padding: 9px 14px; font-size: .74rem; }
}
@media (prefers-reduced-motion: reduce) { .cue span { animation: none; } }
