/* =========================================================
   SIP Digital — homepage energy layer
   Same palette and type as styles.css. This file adds the motion and play:
   scroll progress, word rotator, spinning sticker, big marquee, animated
   card scenes, the "vibes" restyle demo, and the work showcase.
   ========================================================= */
:root { --paper: #fff; --chrome: #2a2733; }

/* ---------- scroll progress ---------- */
.nav__progress { position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; pointer-events: none; }
.nav__progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--sip), var(--lime)); transform-origin: 0 50%; transform: scaleX(0); }
@media (max-width: 1100px) and (min-width: 901px) { .nav__links { gap: 20px; } }

/* ---------- hero: entrance, rotator, spotlight, tilt ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(26px); } }
.hero__copy > * { animation: rise .9s var(--ease) backwards; }
.hero__copy > :nth-child(1) { animation-delay: .05s; }
.hero__copy > :nth-child(2) { animation-delay: .12s; }
.hero__copy > :nth-child(3) { animation-delay: .2s; }
.hero__copy > :nth-child(4) { animation-delay: .28s; }
.hero__copy > :nth-child(5) { animation-delay: .36s; }
.stage { animation: rise 1s .25s var(--ease) backwards; }

.rotator, .rotator__word { display: inline-block; }
.rotator__word { will-change: transform, opacity; }

.hero.is-tracking::after {
  right: auto; left: 0; top: 0;
  transform: translate(calc(var(--mx, 70vw) - 50%), calc(var(--my, 120px) - 50%));
  transition: transform .7s var(--ease);
}
.stage__canvas {
  transform: perspective(1100px) rotateX(var(--tiltx, 0deg)) rotateY(var(--tilty, 0deg));
  transition: transform .5s var(--ease);
}

/* spinning sticker */
.sticker {
  position: absolute; z-index: 6; top: 30px; right: -22px;
  width: 116px; height: 116px; border-radius: 50%;
  background: var(--lime); color: var(--ink);
  display: grid; place-items: center; text-decoration: none;
  box-shadow: 0 14px 30px -12px rgba(0, 0, 0, .7);
  transform: rotate(8deg); transition: transform .4s var(--ease);
}
.sticker svg { position: absolute; inset: 0; width: 100%; height: 100%; animation: spin 18s linear infinite; }
.sticker text { font-family: var(--font-mono); font-size: 10.5px; font-weight: 700; fill: currentColor; }
.sticker__arrow { font-size: 30px; font-weight: 800; line-height: 1; transition: transform .3s var(--ease); }
.sticker:hover { transform: rotate(0deg) scale(1.1); }
.sticker:hover .sticker__arrow { transform: translateX(5px); }

/* ---------- big marquee ---------- */
.bigmarq {
  background: var(--ink); border-top: 1px solid var(--line-dark);
  padding: clamp(18px, 3vw, 36px) 0; overflow: hidden;
  display: grid; gap: clamp(2px, .8vw, 10px);
}
.bigmarq__row { --dir: 1; transform: translateX(calc(var(--shift, 0px) * var(--dir))); will-change: transform; }
.bigmarq__row[data-dir="-1"] { --dir: -1; }
.bigmarq__track { display: flex; width: max-content; margin-left: -30vw; animation: bigmarq 46s linear infinite; }
.bigmarq__row[data-dir="-1"] .bigmarq__track { animation-direction: reverse; }
.bigmarq__set { display: flex; align-items: center; flex: none; }
.bigmarq span {
  font-size: clamp(44px, 9vw, 132px); font-weight: 800; letter-spacing: -0.04em; line-height: 1.02;
  text-transform: uppercase; white-space: nowrap; padding: 0 .12em;
  /* Outlined type: the fill matches the background and paints over the inner half of the stroke,
     which also hides the overlap seams inside the letters. */
  color: var(--ink); -webkit-text-stroke: 3px rgba(245, 239, 228, .62); paint-order: stroke fill;
}
.bigmarq span.fill { color: var(--sip); -webkit-text-stroke: 0; }
.bigmarq span.it { font-family: var(--font-serif); font-style: italic; font-weight: 400; text-transform: none; letter-spacing: -0.01em; color: var(--cream); -webkit-text-stroke: 0; }
.bigmarq i { font-style: normal; color: var(--lime); font-size: clamp(18px, 3vw, 44px); padding: 0 .5em; }
@keyframes bigmarq { to { transform: translateX(-25%); } }

/* ---------- build cards: tilt + animated scenes ---------- */
.builds { perspective: 1400px; }
.build-card.is-tilting { transition: transform .12s linear, box-shadow .4s; }
.build-card::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(circle at var(--gx, 50%) var(--gy, 0%), rgba(255, 255, 255, .2), transparent 45%);
  opacity: 0; transition: opacity .3s;
}
.build-card.is-tilting::after { opacity: 1; }

.art { position: relative; height: 168px; border-radius: 12px; overflow: hidden; margin: -8px -8px 0; }
.art--web { background: var(--cream-2); }
.art--app { background: var(--ink-2); border: 1px solid var(--line-dark); }
.art--both { background: rgba(12, 11, 16, .14); }
.art__scene { position: absolute; left: 50%; top: 0; width: 300px; height: 100%; margin-left: -150px; }

.mini-b { position: absolute; border-radius: 8px; background: var(--paper); border: 1.5px solid var(--ink); overflow: hidden; }
.mini-b::before {
  content: ""; display: block; height: 13px; border-bottom: 1.5px solid var(--ink);
  background:
    radial-gradient(circle at 9px 50%, var(--sip) 2.5px, transparent 3px),
    radial-gradient(circle at 18px 50%, var(--ink) 2.5px, transparent 3px);
}
.ml { display: block; height: 8px; border-radius: 4px; background: var(--ink); margin: 14px 12px 0; width: 70%; }
.ml.s { width: 44%; opacity: .28; margin-top: 8px; }
.mini-p { position: absolute; border-radius: 18px; background: var(--ink); border: 2px solid var(--cream); padding: 12px 8px; display: grid; gap: 7px; align-content: start; }
.mp-top { display: block; height: 34px; border-radius: 8px; background: var(--violet); }
.mp-row { display: block; height: 14px; border-radius: 5px; background: var(--ink-3); }

/* website scene: cursor clicks "Book now", a booking pops */
.art--web .mini-b { left: 14px; top: 22px; width: 190px; height: 124px; }
.mbtn { position: absolute; left: 12px; bottom: 12px; font: 700 10px/1 var(--font-display); background: var(--sip); color: var(--ink); padding: 7px 12px; border-radius: 999px; animation: press 5s infinite; }
.toast {
  position: absolute; right: 10px; top: 16px; background: var(--ink); color: var(--cream);
  font: 700 9.5px/1 var(--font-mono); letter-spacing: .06em; text-transform: uppercase;
  padding: 9px 12px 9px 26px; border-radius: 999px; animation: toast 5s infinite;
  box-shadow: 0 10px 20px -8px rgba(12, 11, 16, .5);
}
.toast::before { content: ""; position: absolute; left: 11px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--lime); }
.cur {
  position: absolute; left: 0; top: 0; width: 15px; height: 20px; background: var(--ink);
  clip-path: polygon(0 0, 0 78%, 26% 60%, 46% 100%, 62% 92%, 42% 54%, 78% 54%);
  transform: translate(236px, 124px); animation: cur-web 5s var(--ease) infinite;
}
@keyframes cur-web {
  0%, 12% { transform: translate(236px, 124px); }
  36%, 39% { transform: translate(64px, 126px); }
  42% { transform: translate(64px, 126px) scale(.8); }
  46% { transform: translate(64px, 126px); }
  74%, 100% { transform: translate(236px, 124px); }
}
@keyframes press { 0%, 39%, 47%, 100% { transform: none; } 42% { transform: scale(.88); } }
@keyframes toast {
  0%, 44% { opacity: 0; transform: translateY(10px) scale(.9); }
  50%, 86% { opacity: 1; transform: none; }
  94%, 100% { opacity: 0; transform: translateY(-6px) scale(.96); }
}

/* app scene: notifications land */
.art--app .mini-p { left: 26px; top: 20px; width: 92px; height: 176px; }
.notif {
  position: absolute; left: 136px; background: var(--ink-3); color: var(--cream);
  font: 700 9.5px/1 var(--font-mono); letter-spacing: .05em; text-transform: uppercase;
  padding: 10px 12px 10px 26px; border-radius: 10px; border: 1px solid var(--line-dark);
  animation: notif 6s var(--ease) infinite both;
}
.notif::before { content: ""; position: absolute; left: 11px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--dot, var(--lime)); }
.notif--1 { top: 26px; }
.notif--2 { top: 68px; --dot: var(--violet); animation-delay: .8s; }
.notif--3 { top: 110px; --dot: var(--sip); animation-delay: 1.6s; }
@keyframes notif {
  0% { opacity: 0; transform: translateX(26px); }
  8%, 84% { opacity: 1; transform: none; }
  92%, 100% { opacity: 0; transform: translateX(-8px); }
}

/* both scene: site and app change together */
.art--both .mini-b { left: 16px; top: 28px; width: 150px; height: 108px; }
.art--both .mini-p { right: 20px; top: 18px; width: 72px; height: 134px; padding: 10px 7px; }
.sync-blk { display: block; height: 36px; margin: 10px 10px 0; border-radius: 6px; animation: sync 6s steps(1) infinite; background: var(--violet); }
.art--both .mini-p .sync-blk { margin: 0; height: 40px; }
.sync-line { position: absolute; left: 168px; top: 82px; width: 38px; border-top: 2px dashed var(--ink); }
.sync-line i { position: absolute; left: 0; top: -6px; width: 10px; height: 10px; border-radius: 50%; background: var(--ink); animation: sync-dot 1.2s ease-in-out infinite alternate; }
@keyframes sync { 0% { background: var(--violet); } 33% { background: var(--lime); } 66% { background: var(--ink-3); } }
@keyframes sync-dot { to { transform: translateX(28px); } }

/* ---------- vibes: one business, four brands ---------- */
.vibe { overflow: hidden; }
.vibe__stage { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 24px; align-items: stretch; }
.vibe__picker { display: grid; gap: 10px; align-content: start; }
.vibe__picker button {
  text-align: left; padding: 18px 20px; border-radius: var(--radius);
  border: 1.5px solid var(--line-dark); background: var(--ink-2); color: var(--cream);
  cursor: pointer; display: grid; gap: 6px;
  transition: background .3s, border-color .3s, color .3s, transform .35s var(--ease);
}
.vibe__picker b { font-size: 26px; letter-spacing: -0.03em; line-height: 1; display: flex; align-items: center; gap: 10px; }
.vibe__picker b::before { content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--sw); flex: none; }
.vibe__picker small { font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted-on-dark); transition: color .3s; }
.vibe__picker button:hover { border-color: rgba(245, 239, 228, .4); transform: translateX(4px); }
.vibe__picker button[aria-pressed="true"] { background: var(--cream); color: var(--ink); border-color: var(--cream); transform: translateX(10px); }
.vibe__picker button[aria-pressed="true"] small { color: var(--muted-on-light); }

.vibe-demo {
  position: relative; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line-dark); background: var(--v-bg); color: var(--v-fg);
  font-family: var(--v-font); min-height: 460px; display: flex; flex-direction: column;
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .9);
}
.vd-bar { display: flex; align-items: center; gap: 7px; padding: 11px 14px; background: var(--ink-2); border-bottom: 1px solid var(--line-dark); font-family: var(--font-mono); font-size: 11px; color: var(--muted-on-dark); }
.vd-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--ink-3); flex: none; }
.vd-bar span { margin-left: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.vd-bar em { margin-left: auto; font-style: normal; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; font-size: 10px; white-space: nowrap; color: var(--lime); }
.vd-page { flex: 1; display: flex; flex-direction: column; gap: clamp(22px, 4vw, 40px); padding: clamp(18px, 3vw, 34px); }
.vd-nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.vd-logo { font-size: 24px; line-height: 1; font-weight: var(--v-hw); font-style: var(--v-hs); letter-spacing: var(--v-ls); text-transform: var(--v-tt); }
.vd-links { display: flex; gap: 22px; font-size: 14px; color: var(--v-muted); }
.vd-links i { font-style: normal; }
.vd-btn {
  display: inline-flex; align-items: center; justify-content: center; align-self: flex-start;
  background: var(--v-accent); color: var(--v-accent-fg); border: var(--v-btn-b);
  border-radius: var(--v-btn-r); padding: 14px 26px; font-weight: 700; font-size: 16px; line-height: 1;
  box-shadow: var(--v-shadow); font-family: var(--v-btn-font, inherit);
}
.vd-btn--sm { padding: 9px 16px; font-size: 13px; }
.vd-hero { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.vd-eyebrow { font-size: 11px; letter-spacing: var(--v-els); text-transform: uppercase; color: var(--v-accent-text); font-weight: 700; }
.vd-h {
  font-size: clamp(36px, 6.4vw, 80px); line-height: .98; font-weight: var(--v-hw); font-style: var(--v-hs);
  letter-spacing: var(--v-ls); text-transform: var(--v-tt);
  transform: rotate(var(--v-rot)); transform-origin: left center;
}
.vd-sub { color: var(--v-muted); max-width: 38ch; font-size: 17px; line-height: 1.4; }
.vd-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: auto; }
.vd-cards div { background: var(--v-card); border: var(--v-card-b); border-radius: var(--v-r); padding: 16px; display: grid; gap: 4px; box-shadow: var(--v-shadow); min-width: 0; }
.vd-cards b { font-size: 17px; font-weight: var(--v-cw); line-height: 1.1; }
.vd-cards i { font-style: normal; font-size: 13px; color: var(--v-muted); }

.vibe-demo, .vd-btn, .vd-cards div, .vd-h, .vd-links, .vd-sub, .vd-eyebrow, .vd-cards i {
  transition: background-color .5s var(--ease), color .5s var(--ease), border-color .5s var(--ease),
    border-radius .5s var(--ease), box-shadow .5s var(--ease), transform .5s var(--ease), letter-spacing .5s var(--ease);
}
.vibe-demo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(100deg, transparent 0, var(--v-accent) 42%, var(--v-accent) 58%, transparent 100%);
  transform: translateX(-110%);
}
.vibe-demo.is-switching::after { animation: wipe .65s var(--ease); }
@keyframes wipe { from { transform: translateX(-110%); } to { transform: translateX(110%); } }

/* the four example brands (demo palettes, deliberately not SIP's own) */
.vibe-demo[data-vibe="bold"] {
  --v-bg: #0c0b10; --v-fg: #f5efe4; --v-muted: #a39d93; --v-accent: #ff5a1f; --v-accent-fg: #fff; --v-accent-text: #ff5a1f;
  --v-card: #1d1a25; --v-card-b: 1px solid transparent; --v-r: 2px; --v-btn-r: 2px; --v-btn-b: 2px solid transparent; --v-shadow: 0 0 0 transparent;
  --v-font: var(--font-display); --v-hw: 800; --v-cw: 800; --v-hs: normal; --v-ls: -0.045em; --v-tt: uppercase; --v-els: .2em; --v-rot: 0deg;
}
.vibe-demo[data-vibe="clean"] {
  --v-bg: #fbfaf6; --v-fg: #1c2321; --v-muted: #66716b; --v-accent: #2f6f5e; --v-accent-fg: #fff; --v-accent-text: #2f6f5e;
  --v-card: #eef1ea; --v-card-b: 1px solid transparent; --v-r: 16px; --v-btn-r: 999px; --v-btn-b: 2px solid transparent; --v-shadow: 0 0 0 transparent;
  --v-font: var(--font-display); --v-hw: 600; --v-cw: 600; --v-hs: normal; --v-ls: -0.03em; --v-tt: none; --v-els: .14em; --v-rot: 0deg;
}
.vibe-demo[data-vibe="luxe"] {
  --v-bg: #15120d; --v-fg: #efe6d2; --v-muted: #a3977e; --v-accent: #c9a45c; --v-accent-fg: #15120d; --v-accent-text: #c9a45c;
  --v-card: transparent; --v-card-b: 1px solid rgba(201, 164, 92, .45); --v-r: 0px; --v-btn-r: 0px; --v-btn-b: 2px solid transparent; --v-shadow: 0 0 0 transparent;
  --v-font: var(--font-serif); --v-hw: 400; --v-cw: 400; --v-hs: italic; --v-ls: -0.01em; --v-tt: none; --v-els: .34em; --v-rot: 0deg;
}
.vibe-demo[data-vibe="playful"] {
  --v-bg: #8b7bff; --v-fg: #0c0b10; --v-muted: #2a2550; --v-accent: #c8f53c; --v-accent-fg: #0c0b10; --v-accent-text: #0c0b10;
  --v-card: #fff; --v-card-b: 2px solid #0c0b10; --v-r: 22px; --v-btn-r: 999px; --v-btn-b: 2px solid #0c0b10; --v-shadow: 4px 4px 0 #0c0b10;
  --v-font: var(--font-display); --v-hw: 800; --v-cw: 800; --v-hs: normal; --v-ls: -0.04em; --v-tt: none; --v-els: .12em; --v-rot: -2deg;
}

.points { list-style: none; padding: 0; margin: clamp(40px, 6vw, 72px) 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; }
.points li { display: grid; gap: 6px; align-content: start; padding-top: 18px; border-top: 1px solid var(--line-dark); }
.points strong { font-size: 20px; letter-spacing: -0.02em; display: flex; gap: 10px; align-items: baseline; }
.points strong::before { content: "✦"; color: var(--lime); font-size: 14px; }
.points span { color: var(--muted-on-dark); font-size: 16px; }

/* ---------- work showcase ---------- */
.reel { position: relative; background: var(--ink-2); }
.reel__chrome { display: flex; align-items: center; gap: 7px; padding: 12px 16px; border-bottom: 1px solid var(--line-dark); }
.reel__chrome i { width: 10px; height: 10px; border-radius: 50%; background: var(--ink-3); }
.reel__url { margin-left: 10px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; color: var(--muted-on-dark); }
.reel__url b { color: var(--cream); font-weight: 700; }
.reel__screen { position: relative; aspect-ratio: 16 / 10; max-width: 100%; overflow: hidden; background: var(--ink); }
.reel__screen img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top;
  opacity: 0; transform: scale(1.06); transition: opacity .7s var(--ease), transform 1.6s var(--ease);
}
.reel__screen img.on { opacity: 1; transform: none; }
.reel__phone {
  position: absolute; z-index: 2; right: 4%; bottom: 5%; width: 17%; aspect-ratio: 780 / 1688;
  border: 5px solid var(--chrome); border-radius: 16px; overflow: hidden; background: var(--ink);
  box-shadow: 0 24px 50px -16px rgba(0, 0, 0, .9); transform: rotate(4deg); transition: transform .5s var(--ease);
}
.work__feature:hover .reel__phone { transform: rotate(0deg) translateY(-8px); }
.reel__phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.reel__tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.reel__tabs button {
  position: relative; overflow: hidden; border: 1px solid var(--line-dark); background: transparent; color: var(--muted-on-dark);
  border-radius: 999px; padding: 10px 16px; cursor: pointer;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase;
  transition: color .2s, border-color .2s, background .2s;
}
.reel__tabs button:hover { color: var(--cream); border-color: rgba(245, 239, 228, .4); }
.reel__tabs button[aria-pressed="true"] { color: var(--ink); border-color: var(--cream); background: var(--cream); }
.reel__tabs .bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--sip); transform: scaleX(0); transform-origin: 0 50%; }
.reel__tabs button[aria-pressed="true"] .bar { animation: tabbar 4.5s linear forwards; }
.work__feature.is-paused .reel__tabs .bar { animation-play-state: paused; }
@keyframes tabbar { to { transform: scaleX(1); } }

/* ---------- CTA band + footer play ---------- */
.cta-band__tag {
  position: absolute; right: clamp(20px, 5vw, 64px); top: clamp(20px, 5vw, 56px);
  background: var(--lime); color: var(--ink); font: 700 12px/1 var(--font-mono); letter-spacing: .14em; text-transform: uppercase;
  padding: 11px 16px; border-radius: 999px; transform: rotate(6deg); box-shadow: 4px 4px 0 var(--ink);
  animation: bob 3.2s ease-in-out infinite;
}
@keyframes bob { 50% { transform: rotate(3deg) translateY(-6px); } }
.cta-band__ring { transition: transform .2s linear; }
.footer__big span { display: inline-block; transition: transform .35s var(--ease), color .25s; }
.footer__big span:hover { transform: translateY(-.08em) rotate(-3deg); color: var(--cream); }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .sticker { top: -14px; right: -4px; width: 92px; height: 92px; }
  .sticker__arrow { font-size: 24px; }
  .vibe__stage { grid-template-columns: 1fr; }
  .vibe__picker { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .vibe__picker button { padding: 14px; }
  .vibe__picker button:hover, .vibe__picker button[aria-pressed="true"] { transform: none; }
  .vibe__picker b { font-size: 20px; }
  .points { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .vibe__picker { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .vibe__picker small { display: none; }
  .vibe-demo { min-height: 420px; }
  .vd-links { display: none; }
  .vd-cards { gap: 8px; }
  .vd-cards div { padding: 12px 10px; }
  .vd-cards b { font-size: 14px; }
  .vd-cards i { font-size: 11px; }
  .vd-bar span { display: none; }
  .reel__phone { width: 22%; border-width: 4px; border-radius: 12px; }
  .cta-band__tag { position: static; display: inline-block; margin-bottom: 20px; }
  .points { grid-template-columns: 1fr; gap: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .bigmarq__track, .sticker svg, .cta-band__tag { animation: none; }
  /* these loops end on a hidden frame, so show them at rest */
  .notif, .toast { animation: none; opacity: 1; transform: none; }
  .stage__canvas { transform: none; }
}
