/* SLYNG v0.x — ink, bone, volt. Unbounded for the loud bits, mono for the small print. */

@font-face {
  font-family: 'Unbounded';
  src: url('fonts/unbounded-800.woff') format('woff');
  font-weight: 800;
  font-display: swap;
}

:root {
  --top: env(safe-area-inset-top, 0px);   /* bumped down in an installed app: status bar, island, mac window controls */
  --ink: #111014;
  --ink-2: #18171c;
  --ink-3: #222127;
  --line: #2c2b32;
  --bone: #f1f0ec;
  --mute: #8d8c93;
  --volt: #d9ff3d;
  --volt-dim: #3a4214;
  --red: #ff5a4e;
  --disp: 'Unbounded', ui-sans-serif, system-ui, sans-serif;
  --body: ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  --mono: ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Consolas, monospace;
  --bar: 56px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { height: 100%; overscroll-behavior: none; }
body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font: 15px/1.45 var(--body);
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--volt); }
[hidden] { display: none !important; }
.disp { font-family: var(--disp); font-weight: 800; letter-spacing: -0.01em; }
.mono { font-family: var(--mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }
:focus-visible { outline: 2px solid var(--volt); outline-offset: 2px; }

.shell { height: 100dvh; display: flex; flex-direction: column; padding-top: var(--top); }

/* ---- top bar */
.bar {
  height: var(--bar); flex: none;
  display: flex; align-items: center; gap: 14px;
  padding: 0 16px; padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right));
  border-bottom: 1px solid var(--line);
  background: var(--ink);
}
.brand { display: flex; align-items: center; }
.brand img { height: 19px; width: auto; display: block; }
.tag { color: var(--mute); white-space: nowrap; }
.tag.live { color: var(--volt); }
.pills { margin-left: auto; display: flex; gap: 6px; min-width: 0; }
.brand { flex: none; }
.pill {
  height: 30px; padding: 0 11px; border: 1px solid var(--line); border-radius: 0; background: transparent;
  color: var(--bone); white-space: nowrap; max-width: 150px; overflow: hidden; text-overflow: ellipsis;
}
.pill:hover { border-color: var(--mute); }
.pill.on { border-color: var(--volt); color: var(--volt); }
.pill { flex: 0 1 auto; min-width: 0; }
.pill.icon { width: 30px; padding: 0; flex: none; }

/* ---- the two panes */
.app { flex: 1; min-height: 0; display: grid; grid-template-columns: 340px 1fr; }
.chats { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); }
.chats-head { display: flex; align-items: center; padding: 18px 16px 10px; }
.chats-head h1 { margin: 0; font-size: 22px; }
.new {
  margin-left: auto; height: 32px; padding: 0 14px; border: 0; background: var(--volt); color: var(--ink);
  font: 800 12px var(--disp); transform: skewX(-10deg);
}
.new:hover { filter: brightness(1.06); }
.chat-list { list-style: none; margin: 0; padding: 4px 8px; overflow-y: auto; flex: 1; }
.chat {
  width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 8px; border: 0; background: none;
  text-align: left; border-radius: 0; border-left: 2px solid transparent;
}
.chat:hover { background: var(--ink-2); }
.chat.on { background: var(--ink-2); border-left-color: var(--volt); }
.chat .mid { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.chat .mid b { font-weight: 600; }
.chat .pv { color: var(--mute); font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat.unread .pv { color: var(--bone); }
.chat .right { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.when { color: var(--mute); font-size: 10px; }
.dot { min-width: 18px; height: 18px; padding: 0 5px; background: var(--volt); color: var(--ink); font: 800 10px/18px var(--disp); text-align: center; }
.list-foot { color: var(--mute); padding: 12px 16px; margin: 0; border-top: 1px solid var(--line); font-size: 10px; }
.empty-list { padding: 24px 16px; color: var(--mute); }
.empty-list .disp { color: var(--bone); font-size: 20px; margin: 0 0 6px; }

.face {
  flex: none; width: 40px; height: 40px; border-radius: 50%; overflow: hidden;
  display: grid; place-items: center; background: var(--ink-3); color: var(--bone);
  font: 800 15px var(--disp); border: 1px solid var(--line);
}
.face img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---- thread */
.thread { position: relative; display: flex; flex-direction: column; min-height: 0; min-width: 0;
  background:
    repeating-linear-gradient(115deg, transparent 0 140px, rgba(255,255,255,0.018) 140px 141px),
    var(--ink);
}
.thread-none { margin: auto; text-align: center; color: var(--mute); padding: 24px; }
.thread-none img { width: 64px; height: 64px; opacity: 0.9; }
.thread-none .disp { color: var(--bone); font-size: 24px; margin: 14px 0 6px; }
.thread-head { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--ink); }
.thread-head .who { display: flex; flex-direction: column; min-width: 0; }
.thread-head .who b { font-weight: 600; font-size: 16px; }
.thread-head .who span { color: var(--mute); font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.back { display: none; width: 34px; height: 34px; border: 1px solid var(--line); background: none; font-size: 18px; }

.msgs { list-style: none; margin: 0; padding: 18px 16px 30px; overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 4px; }
.day { align-self: center; color: var(--mute); font-size: 10px; margin: 14px 0 6px; }
.msg { display: flex; flex-direction: column; max-width: min(78%, 520px); }
.msg.in { align-self: flex-start; align-items: flex-start; }
.msg.out { align-self: flex-end; align-items: flex-end; }
.bub { padding: 9px 13px; border-radius: 16px; overflow-wrap: anywhere; }
.msg.in .bub { background: var(--ink-3); border-bottom-left-radius: 4px; }
.msg.out .bub { background: var(--bone); color: var(--ink); border-bottom-right-radius: 4px; }
.txt { margin: 0; white-space: pre-wrap; }
.msg.sats .bub { background: var(--volt); color: var(--ink); }
.msg.sats.in .bub { background: var(--ink-2); color: var(--bone); border: 1.5px solid var(--volt); }
.amt { font-size: 26px; line-height: 1.05; display: flex; align-items: center; gap: 4px; }
.amt + .txt { margin-top: 4px; }
.msg.sats.in .amt { color: var(--volt); }
.bolt { font-size: 0.8em; }
.meta { color: var(--mute); font-size: 9.5px; margin: 3px 4px 6px; display: flex; gap: 8px; align-items: center; }
.msg.pending .bub { opacity: 0.75; }
.msg.pending.sats .bub { animation: hang 0.9s ease-in-out infinite alternate; }
@keyframes hang { from { transform: translateY(0); } to { transform: translateY(-3px); } }
.msg.bad .meta { color: var(--red); text-transform: none; letter-spacing: 0; font-size: 11px; }
.catch { border: 0; background: none; padding: 0; color: var(--volt); font: inherit; text-decoration: underline; text-underline-offset: 2px; }

.aimed { margin: 0 16px 6px; padding: 8px 10px; border: 1px dashed var(--volt); color: var(--volt); text-transform: none; letter-spacing: 0.02em; font-size: 11.5px; }

/* ---- composer & the slyng */
.composer {
  position: relative; padding: 28px 12px 8px; padding-bottom: max(8px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line); background: var(--ink);
}
#text {
  display: block; width: 100%; resize: none; min-height: 48px; max-height: 160px; padding: 14px 16px 12px; border-radius: 22px;
  background: var(--ink-2); border: 1px solid var(--line); line-height: 1.4; outline: none;
}
#text:focus { border-color: var(--mute); }
.hint { margin: 6px 8px 0; color: #5d5c63; font-size: 9px; text-align: center; }
.tie { position: absolute; left: 18px; top: 6px; display: flex; align-items: center; gap: 8px; color: var(--mute); }
.tie b { color: var(--volt); font-size: 13px; }
.tie span { color: var(--bone); font-size: 10px; text-transform: none; letter-spacing: 0.02em; }
.tie button { border: 1px solid var(--line); background: none; width: 20px; height: 20px; line-height: 1; padding: 0; color: var(--mute); }

/* the Y sits on the top edge of the box, in the middle: grab it and pull down */
.slyng {
  position: absolute; left: 50%; top: -15px; transform: translateX(-50%); z-index: 4;
  width: 72px; height: 56px; padding: 0 0 6px; border: 0; background: none;
  display: flex; align-items: flex-end; justify-content: center;
  touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab;
}
.slyng:active { cursor: grabbing; }
.slyng svg { width: 50px; height: 42px; display: block; overflow: visible; transform-origin: 50% 100%; }
.slyng .body { fill: var(--bone); stroke: var(--ink); stroke-width: 34; paint-order: stroke; }
.slyng .gap { fill: var(--ink); }
.slyng .band, .slyng .stone { fill: var(--volt); }
.slyng .rest .band { stroke: var(--ink); stroke-width: 16; stroke-linejoin: miter; paint-order: stroke; }
.slyng.drawn .rest { opacity: 0; }
.slyng.ready .band { filter: drop-shadow(0 0 14px rgba(217, 255, 61, 0.9)); }
.slyng:hover .body { fill: #fff; }
.slyng:focus-visible { outline: none; }
.slyng:focus-visible svg { outline: 2px solid var(--volt); outline-offset: 4px; }
.slyng.twang svg { animation: twang 0.38s cubic-bezier(.3,1.8,.5,1); }
@keyframes twang { 0% { transform: rotate(0) scaleY(1); } 30% { transform: rotate(-5deg) scaleY(0.94); } 60% { transform: rotate(3deg) scaleY(1.03); } 100% { transform: rotate(0) scaleY(1); } }

/* overlays: the band, the trajectory, the flight */
.range { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 5; overflow: visible; }
.flight { position: absolute; inset: 0; pointer-events: none; z-index: 6; overflow: hidden; }
.readout {
  position: absolute; left: 0; top: 0; display: flex; flex-direction: column; gap: 2px; white-space: nowrap;
  padding: 7px 10px; background: rgba(17, 16, 20, 0.92); border: 1px solid var(--line);
}
.readout b { font-size: 22px; color: var(--volt); line-height: 1.05; }
.readout .type { color: var(--bone); font-size: 11px; text-transform: none; letter-spacing: 0.02em; }
.readout .sub { color: var(--mute); font-size: 9px; }
.missile { position: absolute; left: 0; top: 0; will-change: transform, opacity; }
.m-stone {
  position: absolute; left: -8px; top: -8px; width: 16px; height: 16px; border-radius: 50%; background: var(--volt);
  box-shadow: 0 0 0 2.5px var(--ink), 0 0 22px rgba(217, 255, 61, 0.55);
}
.m-chip {
  position: absolute; left: 14px; top: -12px; height: 24px; padding: 0 10px; border-radius: 12px; white-space: nowrap;
  display: flex; align-items: center; font-size: 13px; background: var(--bone); color: var(--ink);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
}
.missile.sats .m-chip { background: var(--volt); font-weight: 600; }
.missile.flip .m-chip { left: auto; right: 14px; }
.burst {
  position: absolute; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%;
  border: 2px solid var(--bone); animation: burst 0.6s ease-out forwards;
}
.burst.sats { border-color: var(--volt); }
@keyframes burst { from { transform: scale(0.6); opacity: 1; } to { transform: scale(1.9); opacity: 0; } }
.face.hit { animation: hit 0.6s ease-out; }
@keyframes hit { 0% { transform: scale(1); } 25% { transform: scale(0.88); box-shadow: 0 0 0 3px var(--volt); } 100% { transform: scale(1); box-shadow: 0 0 0 0 transparent; } }

/* ---- sheets */
.sheet {
  width: min(440px, calc(100vw - 24px)); max-height: calc(100dvh - 40px); padding: 18px; border: 1px solid var(--line);
  background: var(--ink-2); color: var(--bone); border-radius: 0;
}
.sheet.wide { width: min(560px, calc(100vw - 24px)); }
.sheet::backdrop { background: rgba(10, 9, 12, 0.72); backdrop-filter: blur(3px); }
.sheet-head { display: flex; align-items: center; margin-bottom: 8px; }
.sheet-head h2 { margin: 0; font-size: 20px; }
.x { margin-left: auto; width: 32px; height: 32px; border: 1px solid var(--line); background: none; font-size: 18px; line-height: 1; }
.sheet p { color: #cfcdc7; margin: 8px 0; }
.sheet h3 { color: var(--volt); margin: 18px 0 4px; font-weight: 400; }
.lede { font-size: 17px; color: var(--bone) !important; }
.facts { padding-left: 18px; margin: 8px 0; color: #cfcdc7; }
.facts li { margin: 6px 0; }
.facts b { color: var(--bone); }
.small { font-size: 10px !important; color: var(--mute) !important; }
.sheet input[type=text], .sheet input[type=password] {
  width: 100%; height: 42px; padding: 0 12px; background: var(--ink); border: 1px solid var(--line); outline: none; border-radius: 0;
}
.eco-bal b { font-size: 34px; color: var(--volt); }
.eco-add { display: flex; gap: 8px; align-items: center; margin: 8px 0; }
.eco-add input { flex: 1; }
#eco-pr { display: block; max-height: 4.5em; overflow: auto; word-break: break-all; font-size: 11px; padding: 8px; background: var(--ink-2); }
.sn-at { align-self: center; color: var(--volt); }
.sheet input:focus { border-color: var(--volt); }
.choice {
  width: 100%; display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left;
  padding: 12px 14px; margin: 8px 0; background: var(--ink); border: 1px solid var(--line); border-radius: 0;
}
.choice:hover:not(:disabled) { border-color: var(--volt); }
.choice:disabled { opacity: 0.45; cursor: not-allowed; }
.choice span { color: var(--mute); font-size: 13px; }
.paste { margin: 10px 0; }
.paste summary { cursor: pointer; color: var(--mute); font-size: 13px; padding: 4px 0; }
.paste input { margin: 8px 0; }
.check { display: flex; gap: 8px; align-items: center; color: var(--mute); font-size: 13px; margin-top: 10px; }
.status { min-height: 1em; font-size: 13px; color: var(--mute) !important; }
.status.bad { color: var(--red) !important; }
.cta {
  display: inline-flex; align-items: center; gap: 24px; height: 44px; padding: 0 20px; border: 0;
  background: var(--volt); color: var(--ink); font: 800 13px var(--disp); text-transform: uppercase;
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%); margin-top: 8px;
}
.cta.small { height: 38px; gap: 0; font-size: 12px; }
.ghost { height: 38px; padding: 0 16px; border: 1px solid var(--line); background: none; }
.btns { display: flex; gap: 10px; align-items: center; }
.key, .code {
  background: var(--ink); border: 1px solid var(--line); padding: 10px 12px; white-space: pre-wrap; word-break: break-all;
  text-transform: none; letter-spacing: 0; font-size: 12px; color: var(--volt);
}
.new-row { display: flex; gap: 8px; align-items: center; }
.new-row input { flex: 1; min-width: 0; }
.new-row .cta { margin: 0; flex: none; height: 42px; }
.new-row .cta:disabled { opacity: 0.5; }
.people { list-style: none; margin: 6px 0 0; padding: 0; max-height: 52dvh; overflow-y: auto; }
.person { width: 100%; display: flex; gap: 12px; align-items: center; padding: 8px 4px; border: 0; background: none; text-align: left; }
.person:hover { background: var(--ink-3); }
.person .mid { display: flex; flex-direction: column; min-width: 0; }
.person .mid span { color: var(--mute); font-size: 10px; }

.toast {
  position: fixed; left: 50%; bottom: max(90px, calc(env(safe-area-inset-bottom) + 80px)); transform: translateX(-50%);
  max-width: min(92vw, 460px); padding: 10px 14px; background: var(--bone); color: var(--ink); font-size: 14px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4); z-index: 10;
}

/* ---- phone: one pane at a time */
@media (max-width: 819px) {
  .app { grid-template-columns: 1fr; }
  .chats { border-right: 0; }
  .app[data-view="list"] .thread { display: none; }
  .app[data-view="thread"] .chats { display: none; }
  .back { display: grid; place-items: center; }
  .tag { display: none; }
  .msg { max-width: 84%; }
}
@media (max-width: 380px) {
  .pill { padding: 0 8px; max-width: 110px; }
}
@media (prefers-reduced-motion: reduce) {
  .slyng.twang svg, .msg.pending.sats .bub, .face.hit, .burst { animation: none; }
}

/* ---- the splash: the landing page, with a slyng you can try in place */
.splash {
  position: fixed; inset: var(--top) 0 0 0; z-index: 20; overflow-y: auto; overflow-x: hidden;
  background:
    repeating-linear-gradient(115deg, transparent 0 160px, rgba(255,255,255,0.022) 160px 161px),
    var(--ink);
}
.sp-bar {
  display: flex; align-items: center; height: 64px; max-width: 1180px; margin: 0 auto;
  padding: 0 max(16px, env(safe-area-inset-left));
}
.sp-logo { height: 24px; width: auto; display: block; }
.sp-bar .pill { margin-left: auto; }
.sp-hero {
  max-width: 1180px; margin: 0 auto; padding: 56px 24px 40px;
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center;
}
.kicker { color: var(--volt); margin: 0 0 18px; }
.sp-copy h1 { font-size: clamp(44px, 7vw, 92px); line-height: 0.98; margin: 0; letter-spacing: -0.025em; }
.sp-copy h1 em { font-style: normal; color: var(--volt); }
.sp-lede { font-size: 19px; line-height: 1.5; color: #cfcdc7; max-width: 30em; margin: 26px 0 0; }
.sp-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 30px; }
.sp-ctas .cta { height: 54px; padding: 0 26px; font-size: 15px; margin: 0; }
.sp-ctas .ghost { height: 54px; padding: 0 20px; font-size: 15px; }
.sp-ctas .ghost:hover { border-color: var(--volt); color: var(--volt); }
.sp-note { color: var(--mute); margin: 18px 0 0; font-size: 10px; }

.sp-try {
  position: relative; overflow: hidden; height: 480px; display: flex; flex-direction: column;
  background: var(--ink-2); border: 1px solid var(--line);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(217, 255, 61, 0.04);
}
.sp-try .thread-head { background: var(--ink-2); }
.try-msgs { flex: 1; overflow: hidden; justify-content: flex-end; padding-bottom: 34px; }
.try-comp { background: var(--ink-2); padding-bottom: 14px; }
.try-input {
  display: block; width: 100%; min-height: 48px; max-height: 96px; padding: 14px 16px 12px; border-radius: 22px; resize: none;
  background: var(--ink); border: 1px solid var(--line); outline: none; line-height: 1.4;
}
.try-bal { margin-left: auto; color: var(--volt); font-size: 10px; }
.try-input:focus { border-color: var(--mute); }
.sp-try.done { border-color: rgba(217, 255, 61, 0.45); }
.msg.pop { animation: pop 0.35s cubic-bezier(.2,1.5,.4,1); }
@keyframes pop { from { transform: translateY(8px) scale(0.96); opacity: 0; } to { transform: none; opacity: 1; } }

.sp-steps {
  list-style: none; max-width: 1180px; margin: 0 auto; padding: 24px 24px 56px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
}
.sp-steps li { border: 1px solid var(--line); background: rgba(24, 23, 28, 0.6); padding: 22px 22px 20px; }
.sp-steps .n { color: var(--volt); display: block; margin-bottom: 10px; }
.sp-steps b { font-size: 26px; display: block; }
.sp-steps p { color: #b9b7b1; margin: 10px 0 14px; }
.sp-steps code {
  font: 13px var(--mono); color: var(--volt); background: var(--ink); border: 1px solid var(--line);
  padding: 4px 8px; display: inline-block;
}
.sp-foot {
  max-width: 1180px; margin: 0 auto; padding: 20px 24px 36px; border-top: 1px solid var(--line);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; color: var(--mute); font-size: 10px;
}
.sp-foot a { color: var(--mute); }
.sp-foot a:hover { color: var(--volt); }

@media (max-width: 900px) {
  .sp-hero { grid-template-columns: 1fr; gap: 36px; padding: 32px 16px 28px; }
  .sp-try { height: 380px; }
  .sp-steps { grid-template-columns: 1fr; padding: 8px 16px 40px; }
  .sp-lede { font-size: 17px; }
  .sp-foot { padding: 18px 16px 32px; }
}

/* ---- settings */
.settings { position: fixed; inset: var(--top) 0 0 0; z-index: 15; overflow-y: auto; background: var(--ink); }
.st-bar {
  position: sticky; top: 0; z-index: 1; display: flex; align-items: center; gap: 12px; height: 56px;
  padding: 0 16px; border-bottom: 1px solid var(--line); background: var(--ink);
}
.st-bar h1 { font-size: 20px; margin: 0; }
.st-bar .back { display: grid; place-items: center; }
.st-note { margin: 0; padding: 10px 12px; border: 1px dashed var(--volt); color: var(--volt); }
.st-body { max-width: 640px; margin: 0 auto; padding: 24px 16px 64px; display: flex; flex-direction: column; gap: 16px; }
.st-card { border: 1px solid var(--line); background: var(--ink-2); padding: 18px; }
.st-card h2 { color: var(--volt); font-weight: 400; margin: 0 0 14px; }
.st-card p { color: #cfcdc7; margin: 0 0 12px; }
.st-who { display: flex; gap: 14px; align-items: center; margin-bottom: 18px; }
.st-who div { display: flex; flex-direction: column; min-width: 0; }
.st-who b { font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-who span { color: var(--mute); font-size: 10px; }
.face.big { width: 64px; height: 64px; font-size: 24px; }
.st-card label { display: block; margin: 0 0 16px; font-size: 13px; font-weight: 600; color: var(--bone); }
.hint2 { display: block; font-weight: 400; color: var(--mute); font-size: 12px; margin-top: 2px; }
.st-card input, .st-card textarea {
  display: block; width: 100%; margin-top: 6px; height: 42px; padding: 0 12px; font-weight: 400;
  background: var(--ink); border: 1px solid var(--line); outline: none; border-radius: 0;
}
.st-card textarea { height: auto; padding: 10px 12px; resize: vertical; line-height: 1.4; }
.st-card input:focus, .st-card textarea:focus { border-color: var(--volt); }
.st-card input.bad { border-color: var(--red); }
.st-row { display: flex; gap: 8px; align-items: flex-end; }
.st-row input { flex: 1; min-width: 0; }
.st-row .ghost { height: 42px; flex: none; }
.st-ok { display: block; margin-top: 6px; color: var(--mute); font-size: 10px; font-weight: 400; text-transform: none; letter-spacing: 0.02em; }
.st-ok.good { color: var(--volt); }
.st-ok.bad { color: var(--red); }
.st-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.st-actions .cta { margin: 0; }
.st-actions .status { margin: 0; }
.st-card .btns { flex-wrap: wrap; }
.ghost:hover { border-color: var(--mute); }
.ghost.danger:hover { border-color: var(--red); color: var(--red); }
.st-keynote { font-size: 13px; color: var(--mute) !important; }

/* ---- installed app (PWA) */
html.mac-pwa { --top: 30px; }                 /* Safari web app on a Mac draws its window controls over the page */
.titlebar { display: none; }
html.mac-pwa .titlebar, html.pwa .titlebar {
  display: block; position: fixed; top: 0; left: 0; right: 0; height: var(--top); z-index: 40;
  background: var(--ink); -webkit-app-region: drag; pointer-events: none;
}
html.pwa body { -webkit-tap-highlight-color: transparent; }
html.pwa .bar, html.pwa .chats-head, html.pwa .thread-head, html.pwa .sp-bar, html.pwa .st-bar { -webkit-user-select: none; user-select: none; }
.chat-list, .msgs, .settings, .splash { overscroll-behavior-y: contain; }
.update-pill {
  position: fixed; left: 50%; top: calc(var(--top) + 10px); transform: translateX(-50%); z-index: 50;
  height: 34px; padding: 0 16px; border: 0; border-radius: 17px; background: var(--volt); color: var(--ink);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45); font-size: 10px; white-space: nowrap;
  animation: drop 0.35s cubic-bezier(.2,1.5,.4,1);
}
@keyframes drop { from { transform: translate(-50%, -24px); opacity: 0; } to { transform: translateX(-50%); opacity: 1; } }
.ptr {
  position: fixed; left: 50%; top: calc(var(--top) + 6px); transform: translateX(-50%); z-index: 45;
  height: 28px; padding: 0 12px; border-radius: 14px; display: flex; align-items: center; white-space: nowrap;
  background: var(--ink-3); border: 1px solid var(--line); color: var(--mute); font-size: 9px; pointer-events: none;
}
.ptr.ready { color: var(--ink); background: var(--volt); border-color: var(--volt); }

/* ---- loud: urgency instead of sats, for people with no lightning address */
.msg.loud .bub { font-weight: 600; box-shadow: 0 0 0 2px var(--volt); }
.msg.loud2 .bub { font-size: 17px; box-shadow: 0 0 0 3px var(--volt), 0 0 26px rgba(217, 255, 61, 0.28); }
.msg.loud .meta::before { content: 'loud'; color: var(--volt); }
.msg.loud2 .meta::before { content: 'louder'; }
.missile.loud .m-chip { font-weight: 700; box-shadow: 0 0 0 2px var(--volt), 0 6px 18px rgba(0, 0, 0, 0.45); }
.missile.loud .m-stone { box-shadow: 0 0 0 2.5px var(--ink), 0 0 30px rgba(217, 255, 61, 0.8); }
.burst.loud { border-color: var(--volt); border-width: 3px; }

/* the strike (strike.js), cyanIDE's click lightning in slyng colours: white-hot core, volt glow */
.bolts { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 9998; }
.bolt { fill: none; stroke-linecap: round; stroke-linejoin: round; animation: bolt-flicker 0.5s steps(1, end) forwards; }
.bolt-glow { stroke: var(--bc, var(--volt)); filter: drop-shadow(0 0 6px var(--bc, var(--volt))); }
.bolt-core { stroke: #fff; filter: drop-shadow(0 0 3px var(--bc, var(--volt))); }
.bolt-flash { position: fixed; inset: 0; background: var(--bc, var(--volt)); opacity: 0; pointer-events: none; z-index: 9999; }
.bolt-flash.on { animation: bolt-flash 0.35s ease-out forwards; }
.bolt-spark { position: fixed; font-size: 14px; line-height: 1; pointer-events: none; z-index: 9998; animation: bolt-spark 0.6s ease-out forwards; }
@keyframes bolt-flicker { 0% { opacity: 1; } 15% { opacity: 0.2; } 25% { opacity: 1; } 40% { opacity: 0.35; } 55% { opacity: 1; } 70% { opacity: 0.6; } 100% { opacity: 0; } }
@keyframes bolt-flash { 0% { opacity: 0.14; } 100% { opacity: 0; } }
@keyframes bolt-spark { 0% { opacity: 1; transform: translate(-50%, -50%) scale(0.5) rotate(0deg); } 100% { opacity: 0; transform: translate(var(--tx), var(--ty)) scale(1.2) rotate(120deg); } }

/* the box a bolt hits: the whole box is struck and lights up in the slyng's colour, then their face crackles */
.thread-head.charged { animation: charged 0.6s linear; }
@keyframes charged {
  0% { box-shadow: inset 0 0 0 999px color-mix(in srgb, var(--charge, var(--volt)) 10%, transparent), inset 0 0 0 2px var(--charge, var(--volt)), 0 0 22px var(--charge, var(--volt)); }
  12% { box-shadow: inset 0 0 0 999px color-mix(in srgb, var(--charge, var(--volt)) 3%, transparent), inset 0 0 0 2px #fff, 0 0 10px var(--charge, var(--volt)); }
  22% { box-shadow: inset 0 0 0 999px color-mix(in srgb, var(--charge, var(--volt)) 8%, transparent), inset 0 0 0 2px var(--charge, var(--volt)), 0 0 18px var(--charge, var(--volt)); }
  40% { box-shadow: inset 0 0 0 999px color-mix(in srgb, var(--charge, var(--volt)) 2%, transparent), inset 0 0 0 1px var(--charge, var(--volt)), 0 0 6px var(--charge, var(--volt)); }
  60% { box-shadow: inset 0 0 0 999px color-mix(in srgb, var(--charge, var(--volt)) 4%, transparent), inset 0 0 0 1px var(--charge, var(--volt)), 0 0 8px var(--charge, var(--volt)); }
  100% { box-shadow: inset 0 0 0 999px transparent, inset 0 0 0 0 transparent, 0 0 0 transparent; }
}
@media (prefers-reduced-motion: reduce) { .thread-head.charged { animation: none; } }

/* the bolt on the Y: what you pull back, and what fires */
.slyng .zap { fill: var(--volt); stroke: var(--ink); stroke-width: 22; stroke-linejoin: round; paint-order: stroke; }
.slyng.ready .zap { filter: drop-shadow(0 0 18px rgba(217, 255, 61, 0.9)); }

/* the edge glow (strike.js): the page's edges light up in the slyng's colour when the bolt hits */
.edge-glow { position: fixed; inset: 0; pointer-events: none; z-index: 9997; opacity: 0; box-shadow: inset 0 0 0 3px var(--bc, var(--volt)), inset 0 0 60px -6px var(--bc, var(--volt)); }
.edge-glow.on { animation: edge-glow 0.7s ease-out forwards; }
@keyframes edge-glow { 0% { opacity: var(--ep, 1); } 18% { opacity: calc(var(--ep, 1) * 0.35); } 30% { opacity: calc(var(--ep, 1) * 0.85); } 100% { opacity: 0; } }
