/* Homepage watchlist section (2026-11-22, v2).
 * Loaded after seo.css + site.css and only by index.html, so the shared site.css?v and the
 * landing pages that load it are untouched. Tokens come from seo.css; none is redefined here.
 *
 * One scene, played as phases: a watchlist console (left) and the owner's phone (right).
 *   p0 watching -> p1 proposal on "Payroll" -> p2 Telegram note -> p3 call rings
 *   -> p4 pressed 1 -> p5 time to act -> p6 second signature, frozen.
 * State is CUMULATIVE classes on .wv-stage (is-p1..is-p7) plus the current one (at-N), set by
 * watch.js. The HTML ships with every class set, so no-JS and reduced-motion show the finished
 * picture. CSP is `style-src 'self'`: no inline styles anywhere. */

.wl-lede { max-width: 62ch; color: var(--cream); font-size: 17px; }

/* Pending = orange (owner, 2026-11-22): a proposal that can still be acted on. Used ONLY for the
   pending state; frozen stays rose and normal stays cyan, as on the rest of the site. */
.wv { margin: 8px 0 26px; --wv-pend: #FF9F43; --wv-pend-a: rgba(255, 159, 67, .1); }

.wv-stage {
  position: relative; display: grid; gap: 22px; align-items: center;
  grid-template-columns: 1fr;
  padding: 26px; border: 1px solid var(--line); border-radius: 8px;
  background:
    radial-gradient(120% 90% at 85% 10%, rgba(34, 227, 208, .07), transparent 60%),
    var(--bg-2);
  overflow: hidden;
}
@media (min-width: 820px) {
  .wv-stage { grid-template-columns: minmax(0, 1fr) 236px; gap: 40px; padding: 34px 40px; }
}

/* ── Console ─────────────────────────────────────────────────────────────────────────────── */
.wv-console { position: relative; }
.wv-head {
  display: flex; align-items: center; gap: 12px; padding-bottom: 12px;
  border-bottom: 1px solid var(--line-2);
}
.wv-title { font-weight: 600; color: var(--cream); font-size: 16px; }
.wv-live {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--mono); font-size: 11.5px; color: var(--cyan);
}
.wv-live i { width: 7px; height: 7px; border-radius: 50%; background: var(--cyan);
             animation: blink 1.6s ease-in-out infinite; }
.wv-clock { margin-left: auto; font-family: var(--mono); font-size: 12.5px; color: var(--dim);
            font-variant-numeric: tabular-nums; }

.wv-rows { list-style: none; margin: 0; padding: 0; position: relative; }
.wv-row {
  position: relative; display: grid; align-items: center; column-gap: 12px; row-gap: 6px;
  grid-template-columns: minmax(0, 1fr) auto auto;
  padding: 14px 12px; margin: 0 -12px; border-bottom: 1px solid var(--line);
  border-left: 3px solid transparent;
  transition: background .5s var(--ease), border-color .5s var(--ease);
}
.wv-name { color: var(--cream); font-weight: 600; font-size: 15px; grid-row: 1; }
.wv-net  { font-family: var(--mono); font-size: 11px; color: var(--dim); grid-column: 1; grid-row: 2; }
.wv-bal  { font-family: var(--mono); font-size: 14px; color: var(--cream); grid-column: 2; grid-row: 1 / 3;
           font-variant-numeric: tabular-nums; transition: color .5s var(--ease), opacity .5s; }
.wv-pill {
  grid-column: 3; grid-row: 1 / 3; justify-self: end;
  font-size: 12.5px; font-weight: 600; padding: 4px 10px; border-radius: 999px;
  color: var(--cyan); border: 1px solid rgba(34, 227, 208, .35); white-space: nowrap;
}

/* The one wallet the story happens to. Its pill holds all three words; one shows at a time. */
.wv-state b { font-weight: 600; display: none; }
.wv-state .s-ok { display: inline; }
.wv-sig {
  grid-column: 1 / -1; grid-row: 3; display: flex; align-items: center; gap: 6px;
  max-height: 0; opacity: 0; overflow: hidden;
  transition: max-height .5s var(--ease), opacity .4s;
}
.wv-sig i {
  width: 22px; height: 6px; border-radius: 3px; background: var(--line-2);
  transition: background .4s, box-shadow .4s;
}
.wv-sig .g2, .is-p7 .wv-sig .g1 { display: none; }
.is-p7 .wv-sig .g2 { display: inline; }
.wv-sig em { font-style: normal; font-family: var(--mono); font-size: 11px; color: var(--dim); margin-left: 4px; }

.is-p2 .wv-hit { background: var(--wv-pend-a); border-left-color: var(--wv-pend); }
.is-p2 .wv-hit .wv-pill { color: var(--wv-pend); border-color: rgba(255, 159, 67, .5); }
.is-p2 .wv-state .s-ok { display: none; }
.is-p2 .wv-state .s-prop { display: inline; }
.is-p2 .wv-sig { max-height: 20px; opacity: 1; }
.is-p2 .wv-sig i:first-child { background: var(--wv-pend); box-shadow: 0 0 10px rgba(255, 159, 67, .6); }
.at-2 .wv-hit { animation: wv-flash .9s ease-out 2; }

/* p1: a transfer out of Payroll, screened by who received it. */
.wv-tx {
  grid-column: 1 / -1; grid-row: 4; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px;
  max-height: 0; opacity: 0; overflow: hidden; font-size: 12.5px; color: var(--dim);
  transition: max-height .5s var(--ease), opacity .4s, margin .4s;
}
.wv-tx .wv-amt { font-family: var(--mono); color: var(--cream); }
.wv-tx b {
  font-weight: 600; font-size: 11.5px; color: var(--rose); padding: 2px 8px; border-radius: 999px;
  border: 1px dashed rgba(255, 61, 99, .55);
}
.is-p1 .wv-tx { max-height: 60px; opacity: 1; margin-top: 4px; }
.at-1 .wv-hit { background: rgba(255, 61, 99, .05); }
.at-1 .wv-tx b { animation: wv-flag .8s ease-out 2; }
@keyframes wv-flag { 0% { box-shadow: 0 0 0 0 rgba(255, 61, 99, .55); } 100% { box-shadow: 0 0 0 8px rgba(255, 61, 99, 0); } }

/* p6: proposal still open - the dots wait, the second one breathes. */
.at-6 .wv-sig i:nth-child(2) { animation: wv-wait 1.1s ease-in-out infinite; }

.is-p7 .wv-hit { background: rgba(255, 61, 99, .12); border-left-color: var(--rose); }
.is-p7 .wv-state .s-prop { display: none; }
.is-p7 .wv-state .s-frz { display: inline; }
.is-p7 .wv-hit .wv-pill { color: var(--bg); background: var(--rose); border-color: var(--rose); }
.is-p7 .wv-sig i, .is-p7 .wv-sig i:first-child { background: var(--rose); box-shadow: 0 0 10px rgba(255, 61, 99, .6); }
.is-p7 .wv-hit .wv-bal { color: var(--rose); }

/* The scan line: a soft cyan band that runs down the rows while all is quiet. */
.wv-sweep {
  position: absolute; left: -12px; right: -12px; top: 48px; height: 46px; pointer-events: none;
  background: linear-gradient(to bottom, transparent, rgba(34, 227, 208, .10) 70%, rgba(34, 227, 208, .55) 98%, transparent);
  opacity: 0;
}
.at-0 .wv-sweep { animation: wv-scan 1.3s linear infinite; }

.wv-tick {
  min-height: 2.9em; margin: 14px 0 0; padding-left: 12px;
  border-left: 2px solid var(--line-2);
  font-size: 14px; line-height: 1.45; color: var(--cream);
  transition: border-color .4s;
}
.is-p1 .wv-tick { border-left-color: var(--rose); }
.is-p2 .wv-tick { border-left-color: var(--wv-pend); }
.is-p3 .wv-tick { border-left-color: var(--cyan); }
.is-p6 .wv-tick { border-left-color: var(--lime); }
.is-p7 .wv-tick { border-left-color: var(--rose); }
.wv-tick.is-new { animation: wv-type .45s var(--ease); }

/* ── Phone ───────────────────────────────────────────────────────────────────────────────── */
.wv-phone {
  justify-self: center; width: 236px; height: 440px; padding: 10px;
  border-radius: 34px; background: #000; border: 1px solid var(--line-2);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .9), inset 0 0 0 2px #10161e;
  transition: transform .5s var(--ease);
}
.wv-screen {
  position: relative; height: 100%; border-radius: 26px; overflow: hidden;
  background: linear-gradient(170deg, #121b26 0%, #090d13 70%);
}
.wv-lock { position: absolute; top: 46px; left: 0; right: 0; text-align: center; }
.wv-ltime { display: block; font-size: 48px; font-weight: 600; letter-spacing: -.02em; color: var(--cream);
            line-height: 1; font-variant-numeric: tabular-nums; }
.wv-ldate { display: block; margin-top: 6px; font-size: 13px; color: var(--dim); }

/* Notifications stack newest on top. A card not yet arrived takes no room at all (no height, no
   padding, no margin, invisible border), so the first one to arrive sits at the top. */
.wv-stack { position: absolute; top: 140px; left: 10px; right: 10px; display: flex; flex-direction: column; }
.wv-note, .wv-missed {
  border-radius: 14px; overflow: hidden;
  max-height: 0; padding-top: 0; padding-bottom: 0; margin-bottom: 0;
  background: rgba(241, 235, 222, .09); border: 1px solid transparent;
  opacity: 0; transform: translateY(-14px) scale(.97);
  transition: opacity .45s var(--ease), transform .55s var(--ease), max-height .5s var(--ease),
              padding .5s var(--ease), margin .5s var(--ease), border-color .5s;
}
.wv-note { display: flex; gap: 9px; padding-left: 12px; padding-right: 12px; }
.wv-missed { padding-left: 12px; padding-right: 12px; font-size: 12px; color: var(--lime); }
.wv-app {
  flex: none; width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center;
  background: var(--cyan); color: var(--bg); font-weight: 700; font-size: 14px;
}
.wv-n-risk .wv-app { background: var(--rose); }
.wv-n-frz .wv-app { background: var(--wv-pend); }
.wv-ntext { font-size: 12.5px; line-height: 1.4; color: var(--cream); }
.wv-ntext b { display: block; font-size: 11.5px; color: var(--dim); font-weight: 600; margin-bottom: 1px; }

.is-p1 .wv-n-risk, .is-p3 .wv-n-frz, .is-p5 .wv-missed {
  opacity: 1; transform: none; max-height: 110px; margin-bottom: 8px;
  border-color: rgba(241, 235, 222, .08);
}
.is-p1 .wv-n-risk, .is-p3 .wv-n-frz { padding-top: 11px; padding-bottom: 11px; }
.is-p5 .wv-missed { padding-top: 9px; padding-bottom: 9px; }
.at-1 .wv-phone, .at-3 .wv-phone { animation: wv-buzz .5s ease-in-out 2; }

/* The call screen covers the lock screen during p3-p4. */
.wv-call {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center;
  padding: 48px 18px 22px; text-align: center;
  background: linear-gradient(180deg, #1d130a 0%, #0b0a10 75%);
  opacity: 0; visibility: hidden; transform: scale(1.04);
  transition: opacity .4s var(--ease), transform .5s var(--ease), visibility 0s .4s;
}
.at-4 .wv-call, .at-5 .wv-call {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity .4s var(--ease), transform .5s var(--ease), visibility 0s;
}
.wv-avatar {
  position: relative; width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center;
  background: var(--wv-pend);
}
.wv-avatar svg { width: 28px; height: 28px; fill: var(--bg); }
.wv-avatar::before, .wv-avatar::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--wv-pend); opacity: 0;
}
.at-4 .wv-avatar::before { animation: wv-ring 1.2s ease-out infinite; }
.at-4 .wv-avatar::after  { animation: wv-ring 1.2s ease-out .6s infinite; }
.at-4 .wv-avatar svg { animation: wv-shake .8s ease-in-out infinite; }
.wv-who  { margin-top: 18px; font-size: 19px; font-weight: 600; color: var(--cream); }
.wv-what { margin-top: 2px; font-size: 12.5px; color: var(--wv-pend); }
.wv-say  { margin-top: 16px; font-size: 12.5px; line-height: 1.45; color: var(--dim); }
.wv-key {
  margin-top: auto; width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center;
  font-size: 24px; font-weight: 500; color: var(--cream);
  background: rgba(241, 235, 222, .10); transition: background .25s, color .25s, transform .25s;
}
.at-5 .wv-key { background: var(--lime); color: var(--bg); transform: scale(.92); }
.wv-ok {
  margin-top: 10px; font-size: 12px; color: var(--lime); min-height: 1.4em;
  opacity: 0; transition: opacity .3s .15s;
}
.at-5 .wv-ok { opacity: 1; }

/* ── Steps: the readable version of the scene, and its progress bar ──────────────────────── */
.wv-steps {
  list-style: none; margin: 16px 0 0; padding: 0;
  display: grid; gap: 4px 18px; grid-template-columns: 1fr;
}
@media (min-width: 820px) { .wv-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 22px; } }
@media (min-width: 1100px) { .wv-steps { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.wv-steps li {
  position: relative; padding: 12px 0 0; font-size: 13.5px; line-height: 1.45; color: var(--dim);
  border-top: 2px solid var(--line-2);
}
.wv-steps li::before {
  content: ""; position: absolute; left: 0; right: 0; top: -2px; height: 2px;
  background: currentColor; transform: scaleX(0); transform-origin: left;
}
.wv-steps b { display: block; color: var(--cream); font-weight: 600; font-size: 15px; margin-bottom: 2px; }
.wv-st { display: block; font-family: var(--mono); font-size: 11.5px; margin-bottom: 4px; }
.wv-s0 .wv-st, .wv-s0::before { color: var(--cyan); }
.wv-s1 .wv-st, .wv-s1::before { color: var(--rose); }
.wv-s2 .wv-st, .wv-s2::before { color: var(--wv-pend); }
.wv-s3 .wv-st, .wv-s3::before { color: var(--cyan); }
.wv-s4 .wv-st, .wv-s4::before { color: var(--lime); }
.wv-s5 .wv-st, .wv-s5::before { color: var(--rose); }
/* Done steps are filled; the current one fills over its own duration. watch.js sets
   data-done / data-cur on the figure (attributes, never inline styles). */
.wv[data-done~="0"] .wv-s0::before,
.wv[data-done~="1"] .wv-s1::before,
.wv[data-done~="2"] .wv-s2::before,
.wv[data-done~="3"] .wv-s3::before,
.wv[data-done~="4"] .wv-s4::before,
.wv[data-done~="5"] .wv-s5::before { transform: none; }
.wv[data-cur="0"] .wv-s0::before,
.wv[data-cur="1"] .wv-s1::before,
.wv[data-cur="2"] .wv-s2::before,
.wv[data-cur="3"] .wv-s3::before,
.wv[data-cur="4"] .wv-s4::before,
.wv[data-cur="5"] .wv-s5::before { animation: wv-bar var(--wv-d, 2.4s) linear forwards; }
.wv[data-cur] .wv-steps li b { color: var(--dim); transition: color .3s; }
.wv[data-cur="0"] .wv-s0 b,
.wv[data-cur="1"] .wv-s1 b,
.wv[data-cur="2"] .wv-s2 b,
.wv[data-cur="3"] .wv-s3 b,
.wv[data-cur="4"] .wv-s4 b,
.wv[data-cur="5"] .wv-s5 b { color: var(--cream); }
/* Step durations: the sum of the phases each step covers (see watch.js). */
.wv[data-cur="0"] { --wv-d: 4s; }
.wv[data-cur="1"] { --wv-d: 5s; }
.wv[data-cur="2"] { --wv-d: 4s; }
.wv[data-cur="3"] { --wv-d: 9s; }
.wv[data-cur="4"] { --wv-d: 4s; }
.wv[data-cur="5"] { --wv-d: 5s; }

.wv figcaption { margin-top: 16px; font-size: 12.5px; color: var(--dim); line-height: 1.5; max-width: 80ch; }

.wl-facts {
  list-style: none; margin: 0 0 26px; padding: 0;
  display: grid; gap: 10px 24px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}
.wl-facts li { padding-left: 14px; border-left: 2px solid var(--line-2); color: var(--dim); font-size: 14.5px; }
.wl-facts b { color: var(--cream); font-weight: 600; }

@keyframes wv-scan  { 0% { opacity: 0; transform: translateY(-30px); } 15% { opacity: 1; }
                      85% { opacity: 1; } 100% { opacity: 0; transform: translateY(150px); } }
@keyframes wv-flash { 0% { background: rgba(255, 159, 67, .32); } 100% { background: rgba(255, 159, 67, .1); } }
@keyframes wv-wait  { 0%, 100% { background: var(--line-2); } 50% { background: rgba(255, 159, 67, .5); } }
@keyframes wv-type  { from { opacity: 0; transform: translateX(-6px); } to { opacity: 1; transform: none; } }
@keyframes wv-buzz  { 0%, 100% { transform: none; } 20% { transform: translateX(-3px) rotate(-1deg); }
                      40% { transform: translateX(3px) rotate(1deg); } 60% { transform: translateX(-2px); }
                      80% { transform: translateX(2px); } }
@keyframes wv-ring  { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(2.1); } }
@keyframes wv-shake { 0%, 100% { transform: rotate(0); } 15%, 45% { transform: rotate(-14deg); }
                      30%, 60% { transform: rotate(14deg); } 75% { transform: rotate(0); } }
@keyframes wv-bar   { from { transform: scaleX(0); } to { transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .wv-stage *, .wv-stage *::before, .wv-stage *::after, .wv-steps li::before {
    animation: none !important; transition: none !important;
  }
}

@media (max-width: 819px) {
  .wv-stage { padding: 20px 18px; }
  .wv-phone { width: 220px; height: 440px; }
  .wv-lock { top: 26px; }
  .wv-ltime { font-size: 36px; }
  .wv-stack { top: 92px; }
  .wv-call { padding-top: 34px; }
}
@media (max-width: 420px) {
  .wv-row { grid-template-columns: minmax(0, 1fr) auto; }
  .wv-bal { grid-column: 1; grid-row: 3; font-size: 13px; }
  .wv-pill { grid-column: 2; grid-row: 1 / 3; }
  .wv-sig { grid-row: 4; }
  .wv-tx { grid-row: 5; }
}
