/* Mutual DM streaks, Daily Spark, and the loopback-only Streak Lab. */

.wst-flame-mark {
  display: block;
  width: 1em;
  height: auto;
  overflow: visible;
}

.wst-tk-celebration .wst-flame-mark__inner.is-smooth {
  filter: none;
  opacity: .88;
  transform: scaleX(1.04);
  transform-origin: 50% 74%;
}

.wst-spark-message {
  width: min(100%, 360px);
  margin: 2px auto;
  padding: 10px 0 10px 14px;
  border-left: 2px solid var(--spark-color);
  text-align: left;
}

.wst-spark-message__meta {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--on-ink-muted);
  font: 450 9.5px/1.35 var(--mono);
}
.wst-spark-message__meta > span:first-child,
.wst-spark-message__meta strong { color: var(--spark-color); }
.wst-spark-message__meta strong { font-weight: 600; }

.wst-spark-message__body {
  margin-top: 8px;
  color: var(--on-ink);
  font-size: 14px;
  line-height: 1.42;
  font-weight: 500;
  letter-spacing: -.01em;
}

.wst-spark-message > button {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 44px;
  margin-top: 3px;
  color: var(--spark-color);
  font: 600 9.5px/1 var(--mono);
}

/* TikTok Streaks: plain flame/count in lists and headers, plus milestone sheet. */

@keyframes wst-tk-sheet-in {
  from { opacity: 0; transform: translateY(34px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes wst-tk-backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes wst-tk-handoff-mask {
  0%,66% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes wst-tk-flame-pop {
  0% { opacity: 0; transform: scale(.65); }
  62% { opacity: 1; transform: scale(1.08); }
  100% { opacity: 1; transform: scale(1) rotate(0); }
}

.wst-streak-badge {
  position: relative;
  min-width: 44px;
  width: 44px;
  height: 44px;
  margin: -6px -9px;
  padding: 0;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  color: var(--streak-color);
}

.wst-streak-badge__visual {
  min-width: 0;
  width: auto;
  height: 24px;
  padding: 0;
  border: 0 !important;
  border-radius: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  background: transparent;
}

.wst-streak-badge .wst-flame-mark { font-size: 13px !important; }

.wst-streak-badge__count {
  color: var(--streak-color);
  font: 500 16px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: 0;
}

.wst-streak-mini {
  height: 22px;
  padding: 0;
  border: 0;
  border-radius: 0;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  background: transparent;
  color: var(--streak-color);
  font: 500 16px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: 0;
}

.wst-streak-mini .wst-flame-mark { font-size: 13px !important; }

.wst-tk-overlay {
  position: fixed;
  z-index: 1000;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: rgba(0,0,0,.48);
  touch-action: none;
  animation: none;
}

.wst-tk-overlay.is-embedded { position: absolute; }

.wst-streak-panel.wst-tk-sheet,
.wst-tk-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 430px);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 20px 22px max(10px, env(safe-area-inset-bottom));
  border: 0;
  border-radius: 16px 16px 0 0;
  background: #fff;
  color: #161616;
  text-align: center;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans", Arial, sans-serif;
  box-shadow: 0 -14px 48px rgba(0,0,0,.14);
  touch-action: pan-y;
  scrollbar-width: none;
  animation: wst-tk-sheet-in .32s cubic-bezier(.2,.86,.24,1) both;
}

.wst-tk-sheet::-webkit-scrollbar { display: none; }

.wst-tk-overlay.is-handoff .wst-tk-sheet::after {
  content: "";
  position: absolute;
  z-index: 5;
  inset: 0;
  border-radius: inherit;
  background: inherit;
  pointer-events: none;
  animation: wst-tk-handoff-mask .3s ease-out both;
}

.wst-tk-close {
  position: absolute;
  z-index: 3;
  top: -6px;
  right: 4px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: #161616;
}

.wst-tk-avatars {
  --streak-avatar-size: clamp(64px, 20vw, 78px);
  height: var(--streak-avatar-size);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
}

.wst-tk-avatar {
  width: var(--streak-avatar-size);
  height: var(--streak-avatar-size);
  border: 3px solid #fff;
  border-radius: 50%;
  background-color: #ececef;
  background-position: center;
  background-size: cover;
  display: grid;
  place-items: center;
  color: #55545a;
  font: 700 22px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  box-shadow: 0 0 0 1px rgba(0,0,0,.06);
}

.wst-tk-avatar.is-friend { margin-left: calc(var(--streak-avatar-size) * -.34); }

.wst-tk-title {
  max-width: 356px;
  margin: 0 auto;
  color: #101010;
  font: 750 24px/1.08 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: -.025em;
  text-wrap: balance;
}

.wst-tk-title__lead,
.wst-tk-title__value { display: block; }
.wst-tk-title__value {
  margin-top: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.wst-tk-title-count {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: var(--streak-color);
  vertical-align: -.14em;
  white-space: nowrap;
}

.wst-tk-title-count b {
  color: var(--streak-color);
  font: 750 24px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: -.035em;
}

.wst-tk-title-count .wst-flame-mark { font-size: 24px !important; }

.wst-tk-title-count.is-animated {
  transform-origin: 50% 80%;
  animation: wst-tk-flame-pop .48s cubic-bezier(.18,.89,.32,1.18) both;
}

.wst-tk-title-count.is-muted,
.wst-tk-title-count.is-muted b { color: #9d9da4; }

.wst-tk-description {
  max-width: 340px;
  margin: 17px auto 0;
  color: #65656b;
  font: 400 15px/1.34 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: -.012em;
  text-wrap: pretty;
}

.wst-tk-learn {
  display: inline;
  padding: 0;
  border: 0;
  background: transparent;
  color: #161616;
  font: inherit;
  font-weight: 650;
  text-decoration: none;
}

button.wst-tk-learn { cursor: pointer; }

.wst-tk-rules {
  max-width: 340px;
  margin: 12px auto 0;
  padding: 12px 14px;
  border-radius: 8px;
  background: #f2f2f3;
  color: #65656b;
  font: 400 13px/1.4 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  text-align: left;
}

.wst-tk-milestones {
  width: 100%;
  max-width: 354px;
  margin: 22px auto 0;
  display: grid;
  grid-template-columns: repeat(9, auto);
  align-items: center;
  justify-content: space-between;
}

.wst-tk-milestone {
  min-width: 34px;
  display: grid;
  justify-items: center;
  gap: 5px;
  color: #98989f;
}

.wst-tk-milestone > span {
  width: 30px;
  height: 32px;
  display: grid;
  place-items: center;
  transform-origin: 50% 80%;
}

.wst-tk-milestone > span .wst-flame-mark { font-size: 21px !important; }

.wst-tk-milestone.is-current > span { animation: wst-tk-flame-pop .48s cubic-bezier(.18,.89,.32,1.18) both; }

.wst-tk-milestone small {
  color: inherit;
  font: 400 12px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: 0;
}

.wst-tk-milestone.is-reached { color: #66666c; }

.wst-tk-milestone-link {
  width: 13px;
  height: 2px;
  border-radius: 99px;
  background: #e8e8eb;
}
.wst-tk-milestone-link.is-reached { background: #f3d5c5; }
.wst-tk-milestone-link.is-to-coral.is-reached { background: #f4cec4; }
.wst-tk-milestone-link.is-to-pink.is-reached { background: #f2c5d8; }
.wst-tk-milestone-link.is-to-violet.is-reached { background: #e4c9ef; }

.wst-tk-primary {
  width: 100%;
  min-height: 48px;
  margin-top: 24px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fe2c55;
  color: #fff;
  font: 650 16px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  letter-spacing: -.01em;
  cursor: pointer;
}

.wst-tk-primary:active { transform: scale(.99); background: #ea244b; }

.wst-tk-celebration {
  position: fixed;
  z-index: 1100;
  inset: 0;
  overflow: hidden;
  isolation: isolate;
  color: #fff;
  pointer-events: auto;
}

.wst-tk-celebration.is-embedded { position: absolute; }

.wst-tk-celebration__veil {
  position: absolute;
  z-index: 0;
  inset: 0;
  background: rgba(5,5,8,.58);
  pointer-events: none;
}

.wst-tk-celebration__light-field {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 35%;
  width: min(118vw,460px);
  height: min(130vw,506px);
  opacity: .52;
  transform: translate(-50%,-50%);
  transform-origin: 50% 50%;
  pointer-events: none;
}

.wst-tk-celebration__halo {
  position: absolute;
  inset: 6% 0 1%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 43%, rgba(255,92,226,.42) 0 8%, rgba(226,35,216,.18) 29%, rgba(125,40,202,.08) 48%, transparent 68%);
}

.wst-tk-celebration__light-field > svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.wst-tk-celebration__light-rays { opacity: 0; }
.wst-tk-celebration__light-field .is-ray { fill: rgba(255,70,219,.075); }
.wst-tk-celebration__light-field .is-ray.is-soft { fill: rgba(152,75,255,.06); }
.wst-tk-celebration__light-field .is-ray.is-low { fill: rgba(255,82,210,.045); }
.wst-tk-celebration__light-field .is-ray.is-right { fill: rgba(128,58,243,.05); }

.wst-tk-celebration__impact-ring {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 35%;
  width: min(56vw,220px);
  aspect-ratio: 1;
  border: 1.5px solid rgba(255,201,246,.82);
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%,-50%) scale(.28);
  pointer-events: none;
}

.wst-tk-celebration__particles {
  position: absolute;
  z-index: 2;
  inset: 0;
  pointer-events: none;
}

.wst-tk-celebration__particles.is-front { z-index: 6; }

.wst-tk-celebration__particles i {
  position: absolute;
  left: 50%;
  top: 35%;
  width: 4px;
  height: 11px;
  border-radius: 1px;
  background: #fa31c5;
  opacity: 0;
  transform-origin: center;
}

.wst-tk-celebration__particles i.is-diamond {
  width: 7px;
  height: 7px;
  border-radius: 1px;
  background: #a948f4;
}

.wst-tk-celebration__particles i.is-star {
  width: 9px;
  height: 9px;
  border-radius: 0;
  background: #ffd36a;
  clip-path: polygon(50% 0,60% 40%,100% 50%,60% 60%,50% 100%,40% 60%,0 50%,40% 40%);
}

.wst-tk-celebration__particles i:nth-child(3n+2) { background: #b14cf5; }
.wst-tk-celebration__particles i:nth-child(5n) { background: #ffd36a; }
.wst-tk-celebration__particles.is-front i { width: 5px; height: 14px; }
.wst-tk-celebration__particles.is-front i.is-diamond { width: 8px; height: 8px; }
.wst-tk-celebration__particles.is-front i.is-star { width: 10px; height: 10px; }

.wst-tk-celebration__hero-anchor {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: clamp(96px,17.5vh,146px);
  top: clamp(96px,17.5dvh,146px);
  width: min(78vw,304px);
  height: min(92vw,358px);
  transform: translateX(-50%);
  transform-origin: 50% 62%;
  pointer-events: none;
}

.wst-tk-celebration__ignition {
  position: absolute;
  z-index: 5;
  left: 50%;
  top: min(34vw,133px);
  width: min(6.7vw,26px);
  height: min(11.8vw,46px);
  border-radius: 72% 38% 66% 42%;
  background: radial-gradient(ellipse at 50% 70%, rgba(255,255,255,.98) 0 10%, rgba(255,158,230,.9) 34%, rgba(245,32,207,.44) 64%, transparent 78%);
  opacity: 0;
  transform: translateX(-50%);
  transform-origin: center;
}

.wst-tk-celebration__mark {
  position: absolute;
  z-index: 2;
  left: 50%;
  top: 0;
  width: min(53vw,206px);
  aspect-ratio: 48 / 59;
  opacity: 1;
  transform: translateX(-50%);
  transform-origin: 50% 74%;
}

.wst-tk-celebration__flame-breathe,
.wst-tk-celebration__inner-shell {
  position: absolute;
  inset: 0;
  display: block;
  transform-origin: 50% 76%;
}

.wst-tk-celebration__flame-layer {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.wst-tk-celebration__flame-layer.is-depth { transform: scale(.996); }
.wst-tk-celebration__flame-layer.is-outer { z-index: 1; }
.wst-tk-celebration__inner-shell { z-index: 2; }
.wst-tk-celebration__inner-shell { transform: translateY(-8px) scale(.78,.82); }
.wst-tk-celebration__flame-sheen {
  opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
}

.wst-tk-celebration__ribbon {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: min(45.5vw,178px);
  width: min(61vw,238px);
  height: min(14vw,54px);
  opacity: 1;
  transform: translateX(-50%);
  transform-origin: center;
}

.wst-tk-celebration__ribbon > svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.wst-tk-celebration__ribbon .is-tail { fill: var(--celebration-ribbon-dark); }
.wst-tk-celebration__ribbon .is-fold { fill: var(--celebration-fold); }
.wst-tk-celebration__ribbon .is-body { fill: var(--celebration-ribbon); }
.wst-tk-celebration__ribbon .is-body-shade { fill: var(--celebration-ribbon-dark); opacity: .16; }

.wst-tk-celebration__count {
  position: absolute;
  z-index: 4;
  left: 50%;
  top: min(39.5vw,154px);
  width: 100%;
  height: min(20vw,78px);
  opacity: 1;
  transform: translateX(-50%);
  transform-origin: 50% 70%;
}

.wst-tk-celebration__count span {
  position: absolute;
  left: 50%;
  top: 0;
  color: #fff;
  font: 900 clamp(49px,15.6vw,64px)/.96 "Manrope", "Arial Black", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: -.045em;
  transform: translateX(-50%);
  paint-order: stroke fill;
  white-space: nowrap;
}

.wst-tk-celebration__count .is-shadow {
  -webkit-text-stroke: 5px var(--celebration-ribbon-dark);
  text-shadow: 0 2px 0 rgba(54,3,49,.13);
}
.wst-tk-celebration__count .is-stroke { -webkit-text-stroke: 2px var(--celebration-ribbon-bright); }
.wst-tk-celebration__count .is-fill { -webkit-text-stroke: 0; }

.wst-tk-celebration.is-reduced .wst-tk-celebration__light-field { opacity: .5; }
.wst-tk-celebration.is-reduced .wst-tk-celebration__impact-ring,
.wst-tk-celebration.is-reduced .wst-tk-celebration__ignition,
.wst-tk-celebration.is-reduced .wst-tk-celebration__particles { display: none; }

/* Local-only product showcase: one phone, no external HUD. */
@keyframes wst-local-lab-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.wst-local-lab {
  position: fixed;
  z-index: 3000;
  inset: 0;
  overflow: hidden;
  background: #e8e8eb;
  color: #161823;
  --ink: #fff;
  --ink-2: #f7f7f8;
  --paper: #f7f7f8;
  --on-ink: #161823;
  --on-ink-muted: #65656b;
  --on-ink-faint: #929299;
  --on-paper: #161823;
  --hair-ink: rgba(22,24,35,.10);
  --hair-paper: rgba(22,24,35,.10);
  --red: #dc2626;
  --red-glow: rgba(220,38,38,.12);
  --r-card: 12px;
  --pad-x: 18px;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  animation: none;
}

.wst-local-lab__workspace {
  width: 100%;
  height: 100%;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wst-local-lab__product {
  position: relative;
  width: min(390px, 100vw);
  height: min(844px, calc(100dvh - 40px));
  min-height: min(640px, 100dvh);
  flex: 0 0 auto;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,.07);
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(0,0,0,.16), 0 3px 12px rgba(0,0,0,.08);
  isolation: isolate;
}

.wst-local-inbox,
.wst-local-chat,
.wst-local-home,
.wst-local-feed,
.wst-local-profile {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: #fff;
  color: #161823;
}

.wst-local-inbox__header {
  min-height: 104px;
  padding: 28px 20px 14px;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  gap: 12px;
  border-bottom: 1px solid #ededf0;
}

.wst-local-inbox__header > div { flex: 1; }
.wst-local-inbox__header div > span,
.wst-local-inbox__header div > strong { display: block; }
.wst-local-inbox__header div > span { color: #88888f; font-size: 12px; }
.wst-local-inbox__header div > strong { margin-top: 2px; font-size: 28px; line-height: 1; letter-spacing: -.035em; }
.wst-local-inbox__header > button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #f2f2f4;
}
.wst-local-inbox__header > button:last-child { margin-left: auto; }

.wst-local-inbox__search {
  height: 38px;
  margin: 12px 16px 4px;
  padding: 0 12px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f1f1f3;
  color: #96969d;
  font-size: 14px;
}

.wst-local-inbox__rows { padding: 0 0 0 16px; }
.wst-local-inbox__rows > button {
  min-height: 76px !important;
  border: 0 !important;
  border-bottom: 1px solid #ededf0 !important;
  border-radius: 0 !important;
  background: #fff !important;
  box-shadow: none !important;
  transform: none !important;
}
.wst-local-inbox__rows > button > div:first-child {
  width: 54px !important;
  height: 54px !important;
  margin: 11px 0 !important;
  overflow: hidden;
  border-radius: 50% !important;
}
.wst-local-inbox__rows > button > div:first-child > div { border: 0 !important; }
.wst-local-inbox__rows > button > div:nth-child(2) { padding: 10px 11px !important; }
.wst-local-inbox__rows > button > div:last-child { padding: 0 14px 0 5px !important; }
.wst-local-inbox__quiet {
  padding: 26px 16px;
  color: #ababaf;
  font-size: 12px;
  text-align: center;
}

.wst-local-chat { display: flex; flex-direction: column; }
.wst-local-chat__header {
  position: relative;
  z-index: 4;
  min-height: 78px;
  padding: 18px 12px 12px;
  border-bottom: 1px solid #e9e9ec;
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(255,255,255,.96);
}

.wst-local-chat__header > button {
  width: 36px;
  height: 44px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
}
.wst-local-chat__header > img {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 50%;
  object-fit: cover;
}
.wst-local-chat__header > div { flex: 1; min-width: 0; }
.wst-local-chat__name { display: flex; align-items: center; gap: 1px; }
.wst-local-chat__name > strong { overflow: hidden; font-size: 16px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.wst-local-chat__header > div > span { display: block; margin-top: 2px; color: #96969d; font-size: 11px; }
.wst-local-chat__name .wst-streak-badge { margin-left: -5px; }

.wst-local-chat__messages {
  flex: 1;
  min-height: 0;
  overflow: hidden;
  padding: 18px 14px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  background: #f7f7f8;
}
.wst-local-chat__day {
  align-self: center;
  margin: 0 0 18px;
  color: #a3a3a8;
  font-size: 11px;
}
.wst-local-chat__bubble {
  max-width: 76%;
  margin-top: 7px;
  padding: 10px 13px;
  border-radius: 16px 16px 16px 4px;
  background: #fff;
  color: #202024;
  font-size: 14px;
  line-height: 1.35;
  box-shadow: 0 1px 0 rgba(0,0,0,.04);
}
.wst-local-chat__bubble.is-me {
  align-self: flex-end;
  border-radius: 16px 16px 4px 16px;
  background: #fe2c55;
  color: #fff;
}
.wst-local-chat__bubble.is-arriving {
  transform-origin: 0 100%;
  animation: wst-local-message-arrive .34s cubic-bezier(.16,1,.3,1) both;
}
@keyframes wst-local-message-arrive {
  from { opacity: 0; transform: translateY(8px) scale(.96); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.wst-local-chat__waiting {
  align-self: flex-end;
  margin: 5px 4px 0 0;
  color: #aaaab0;
  font-size: 10px;
}
.wst-local-chat__streak-event {
  align-self: center;
  margin-top: 22px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #ef385f;
  font-size: 12px;
  font-weight: 600;
}
.wst-local-chat__streak-event.is-risk { color: #99999f; }
.wst-local-chat__streak-event.is-upgrading {
  transform-origin: 50% 80%;
  animation: wst-tk-flame-pop .46s cubic-bezier(.18,.89,.32,1.18) both;
}
.wst-local-chat__composer {
  min-height: 66px;
  padding: 9px 10px max(9px, env(safe-area-inset-bottom));
  border-top: 1px solid #e9e9ec;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
}
.wst-local-chat__composer > button {
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  color: #55555a;
}
.wst-local-chat__composer > button:last-child { border-radius: 50%; background: #fe2c55; color: #fff; }
.wst-local-chat__composer > span {
  height: 40px;
  flex: 1;
  padding: 0 14px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  background: #f1f1f3;
  color: #a0a0a5;
  font-size: 14px;
}

.wst-local-chat__composer.is-active > span { color: #55555c; box-shadow: inset 0 0 0 1px rgba(254,44,85,.3); }
.wst-local-chat__messages.is-spark { gap: 0; }
.wst-local-spark-prompt { margin: 0 14px; padding: 9px 0; }
.wst-local-spark-card { width: 100%; margin-top: 18px; animation: wst-local-message-arrive .38s cubic-bezier(.16,1,.3,1) both; }
.wst-local-spark-card .wst-spark-message { width: calc(100% - 8px); margin: 0 4px; }

.wst-local-home { overflow-y: auto; background: #fff; }
.wst-local-home__header { padding: 28px 22px 20px; border-bottom: 1px solid #ececef; }
.wst-local-home__brand { display: flex; align-items: center; gap: 8px; }
.wst-local-home__brand b { font-size: 17px; letter-spacing: -.04em; }
.wst-local-home__brand b::first-letter { color: #161823; }
.wst-local-home__brand span { color: #fe2c55; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.wst-local-home__header > button { position: absolute; top: 19px; right: 14px; width: 44px; height: 44px; display: grid; place-items: center; color: #6d6d73; }
.wst-local-home__header h1 { margin-top: 24px; color: #101014; font-size: 35px; line-height: 1.01; letter-spacing: -.045em; font-weight: 760; }
.wst-local-home__header p { max-width: 320px; margin-top: 12px; color: #77777e; font-size: 14px; line-height: 1.45; }
.wst-local-home__features { padding: 0 0 26px 18px; }
.wst-local-home__feature { border-bottom: 1px solid #ececef; }
.wst-local-home__feature > button,
button.wst-local-home__feature.is-row { width: 100%; min-height: 112px; padding: 15px 17px 15px 0; display: flex; align-items: center; gap: 14px; text-align: left; }
button.wst-local-home__feature.is-row { border-bottom: 1px solid #ececef; }
.wst-local-home__feature > button > svg,
button.wst-local-home__feature.is-row > svg { flex: 0 0 auto; color: #a2a2a8; }
.wst-local-home__feature-copy { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wst-local-home__feature-copy small { color: #9a9aa0; font-size: 9px; font-weight: 650; letter-spacing: .11em; text-transform: uppercase; }
.wst-local-home__feature-copy strong { margin-top: 4px; color: #17171b; font-size: 18px; line-height: 1.1; letter-spacing: -.02em; }
.wst-local-home__feature-copy > span { margin-top: 5px; color: #77777e; font-size: 12.5px; line-height: 1.35; }
.wst-local-home__streak-icon,
.wst-local-home__glyph,
.wst-local-home__avatar-pair { position: relative; width: 68px; height: 68px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 20px; background: #f4f4f6; }
.wst-local-home__streak-icon { background: radial-gradient(circle at 52% 58%, rgba(243,27,212,.22), transparent 58%), #f6f2f7; color: #f31bd4; }
.wst-local-home__streak-icon b { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%) scaleX(1.08); color: #fff; font: 900 18px/1 "Arial Black", sans-serif; -webkit-text-stroke: 2px #f31bd4; paint-order: stroke fill; }
.wst-local-home__glyph.is-spark { background: #18181b; color: #fff; font-size: 32px; }
.wst-local-home__glyph.is-pulse { background: #fe2c55; color: #fff; }
.wst-local-home__avatar-pair { display: flex; justify-content: center; background: #f1f1f3; }
.wst-local-home__avatar-pair img { width: 40px; height: 40px; border: 2px solid #f1f1f3; border-radius: 50%; object-fit: cover; }
.wst-local-home__avatar-pair img + img { margin-left: -13px; }
.wst-local-home__milestones { padding: 0 16px 14px 0; display: grid; grid-template-columns: repeat(6,1fr); gap: 5px; }
.wst-local-home__milestones button { min-height: 48px; padding: 4px 1px; border-radius: 10px; display: grid; place-items: center; gap: 2px; background: #f6f6f7; color: #77777e; }
.wst-local-home__milestones span { font-size: 9px; }

.wst-local-feed { display: flex; flex-direction: column; background: #fff; }
.wst-local-feed__header { min-height: 76px; padding: 22px 17px 12px; border-bottom: 1px solid #ececef; display: flex; align-items: center; gap: 12px; }
.wst-local-feed__header > button { width: 38px; height: 38px; display: grid; place-items: center; }
.wst-local-feed__header strong { flex: 1; font-size: 25px; letter-spacing: -.05em; }
.wst-local-feed__header strong span { color: #dc2626; }
.wst-local-feed__header small { color: #9a9aa1; font: 600 8px/1 ui-monospace, monospace; letter-spacing: .12em; text-transform: uppercase; }
.wst-local-feed__scroll { flex: 1; min-height: 0; overflow-y: auto; padding-bottom: 26px; }
.wst-local-feed__stories { height: 82px; padding: 13px 18px; border-bottom: 1px solid #ececef; display: flex; align-items: center; gap: 13px; }
.wst-local-feed__story { position: relative; width: 54px; height: 54px; flex: 0 0 auto; border: 2px solid #dc2626; border-radius: 50%; padding: 2px; }
.wst-local-feed__story img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.wst-local-feed__story i { position: absolute; right: -3px; bottom: -2px; width: 18px; height: 18px; border: 2px solid #fff; border-radius: 50%; display: grid; place-items: center; background: #dc2626; color: #fff; font-size: 12px; font-style: normal; }
.wst-local-feed__story.is-quiet { border-color: #e4e4e7; background: #f2f2f4; }
.wst-local-feed__compose { width: calc(100% - 36px); min-height: 64px; margin: 13px 18px; padding: 10px 0; border-bottom: 1px solid #ececef; display: flex; align-items: center; gap: 10px; text-align: left; }
.wst-local-feed__compose img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.wst-local-feed__compose span { flex: 1; color: #98989e; font-size: 13px; }
.wst-local-feed__compose b { color: #dc2626; font-size: 10px; }
.wst-local-feed .wst-local-feed__scroll > section { margin-top: 0 !important; }
.wst-local-feed__post { margin-top: 2px; padding: 18px; border-top: 1px solid #ececef; color: #1b1b20; }
.wst-local-feed__post.is-new { animation: wst-local-message-arrive .42s cubic-bezier(.16,1,.3,1) both; }
.wst-local-feed__post header { display: flex; align-items: center; gap: 10px; }
.wst-local-feed__post header img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.wst-local-feed__post header div { display: flex; flex-direction: column; gap: 2px; }
.wst-local-feed__post header strong { font-size: 13px; }
.wst-local-feed__post header span { color: #9a9aa1; font-size: 10px; }
.wst-local-feed__post > small { display: inline-block; margin-top: 14px; color: #dc2626; font: 700 9px/1 ui-monospace, monospace; letter-spacing: .1em; text-transform: uppercase; }
.wst-local-feed__post h2 { margin-top: 7px; font-size: 14px; line-height: 1.35; }
.wst-local-feed__post p { margin-top: 12px; color: #36363b; font-size: 14px; line-height: 1.5; }
.wst-local-feed__post footer { margin-top: 15px; display: flex; align-items: center; gap: 22px; color: #8d8d94; font-size: 11px; }
.wst-local-feed__post footer span:last-child { margin-left: auto; }
.wst-local-feed__composer { position: absolute; z-index: 20; inset: 0; overflow: hidden; background: #fff; animation: wst-tk-sheet-in .32s cubic-bezier(.16,1,.3,1) both; }

.wst-local-profile { overflow-y: auto; background: #08080a; }
.wst-local-profile > .nd-scope { min-height: 100%; }

.wst-local-lab-launcher {
  position: fixed;
  z-index: 3000;
  right: 14px;
  bottom: calc(var(--tab-h) + env(safe-area-inset-bottom) + 12px);
  min-height: 42px;
  padding: 0 14px;
  border-radius: 22px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #17171a;
  color: #fff;
  font: 650 11px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  box-shadow: 0 10px 30px rgba(0,0,0,.24);
}

@media (max-width: 759px) {
  .wst-local-lab__workspace { padding: 0; display: block; }
  .wst-local-lab__product { width: 100%; height: 100dvh; min-height: 0; border: 0; border-radius: 0; box-shadow: none; }
  .wst-local-chat__header { padding-top: calc(18px + env(safe-area-inset-top)); min-height: calc(78px + env(safe-area-inset-top)); }
  .wst-local-inbox__header { padding-top: calc(28px + env(safe-area-inset-top)); min-height: calc(104px + env(safe-area-inset-top)); }
  .wst-local-home__header { padding-top: calc(28px + env(safe-area-inset-top)); }
  .wst-local-home__header > button { top: calc(19px + env(safe-area-inset-top)); }
  .wst-local-feed__header { padding-top: calc(22px + env(safe-area-inset-top)); min-height: calc(76px + env(safe-area-inset-top)); }
}

/* DMs use the same quiet, native row grammar as the streak reference. Group
   rooms intentionally keep the existing WST cards and cover treatment. */
.wst-chat-row.is-dm {
  min-height: 76px;
  border: 0 !important;
  border-bottom: 1px solid var(--hair-ink) !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}
.wst-chat-row.is-dm:hover { transform: none !important; }
.wst-chat-row.is-dm .wst-chat-row__avatar {
  width: 54px !important;
  height: 54px !important;
  margin: 11px 0;
  overflow: hidden;
  border-radius: 50%;
}
.wst-chat-row.is-dm .wst-chat-row__avatar-image,
.wst-chat-row.is-dm .wst-chat-row__avatar-fallback { border: 0 !important; }
.wst-chat-row.is-dm .wst-chat-row__body { padding: 11px 12px !important; gap: 5px !important; }
.wst-chat-row.is-dm .wst-chat-row__title { gap: 3px !important; }
.wst-chat-row.is-dm .wst-chat-row__title > span:first-child { font-size: 15px !important; font-weight: 650 !important; }
.wst-chat-row.is-dm .wst-chat-row__preview { font-size: 13px !important; }
.wst-chat-row.is-dm .wst-chat-row__meta { padding: 0 4px 0 8px !important; gap: 6px !important; }
.wst-chat-row.is-dm .wst-chat-row__time { font: 400 11px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important; letter-spacing: 0 !important; }
.wst-chat-row.is-dm .wst-chat-row__unread { min-width: 20px !important; height: 20px !important; box-shadow: none !important; }

.wst-chat-spark-prompt {
  margin: 0 var(--pad-x);
  padding: 10px 0;
  border-bottom: 1px solid var(--hair-ink);
  display: flex;
  align-items: center;
  gap: 9px;
}

.wst-chat-spark-prompt > i { color: var(--red); font-style: normal; }
.wst-chat-spark-prompt > span { flex: 1; min-width: 0; color: var(--on-ink-muted); font-size: 12.5px; line-height: 1.35; }
.wst-chat-spark-prompt > button { min-width: 44px; min-height: 44px; color: var(--red); font: 650 10px/1 var(--sans); }

[data-theme="dark"] .wst-tk-sheet {
  background: #1c1c1e;
  color: #f5f5f7;
  box-shadow: 0 -14px 48px rgba(0,0,0,.36);
}

[data-theme="dark"] .wst-tk-title,
[data-theme="dark"] .wst-tk-close { color: #f5f5f7; }
[data-theme="dark"] .wst-tk-description { color: #aaaab0; }
[data-theme="dark"] .wst-tk-learn { color: #f5f5f7; }
[data-theme="dark"] .wst-tk-rules { background: #2a2a2d; color: #b9b9be; }
[data-theme="dark"] .wst-tk-avatar { border-color: #1c1c1e; background-color: #353539; color: #e7e7ea; }
[data-theme="dark"] .wst-tk-milestone.is-reached { color: #c0c0c5; }
[data-theme="dark"] .wst-tk-milestone-link { background: #3a3a3e; }
[data-theme="dark"] .wst-tk-milestone-link.is-reached { background: #76545f; }
[data-theme="dark"] .wst-tk-milestone-link.is-to-pink.is-reached { background: #775064; }
[data-theme="dark"] .wst-tk-milestone-link.is-to-violet.is-reached { background: #66506f; }

/* The local fixture is a fixed light reference surface even when the WST
   theme behind it changes; this keeps comparisons deterministic. */
[data-theme="dark"] .wst-local-lab .wst-tk-sheet { background: #fff; color: #161616; box-shadow: 0 -14px 48px rgba(0,0,0,.14); }
[data-theme="dark"] .wst-local-lab .wst-tk-title,
[data-theme="dark"] .wst-local-lab .wst-tk-close,
[data-theme="dark"] .wst-local-lab .wst-tk-learn { color: #161616; }
[data-theme="dark"] .wst-local-lab .wst-tk-description { color: #65656b; }
[data-theme="dark"] .wst-local-lab .wst-tk-avatar { border-color: #fff; }
[data-theme="dark"] .wst-local-lab .wst-tk-milestone.is-reached { color: #66666c; }
[data-theme="dark"] .wst-local-lab .wst-tk-milestone-link { background: #e8e8eb; }
[data-theme="dark"] .wst-local-lab .wst-tk-milestone-link.is-reached { background: #f3d5c5; }
[data-theme="dark"] .wst-local-lab .wst-tk-milestone-link.is-to-coral.is-reached { background: #f4cec4; }
[data-theme="dark"] .wst-local-lab .wst-tk-milestone-link.is-to-pink.is-reached { background: #f2c5d8; }
[data-theme="dark"] .wst-local-lab .wst-tk-milestone-link.is-to-violet.is-reached { background: #e4c9ef; }

@media (max-width: 360px) {
  .wst-tk-title { font-size: 22px; }
  .wst-tk-description { font-size: 14px; }
  .wst-tk-avatars { margin-bottom: 16px; }
  .wst-tk-milestones { margin-top: 19px; }
  .wst-tk-milestone { min-width: 30px; }
  .wst-tk-milestone > span { width: 28px; height: 30px; }
  .wst-tk-milestone > span .wst-flame-mark { font-size: 21px !important; }
  .wst-tk-milestone-link { width: 8px; }
  .wst-tk-primary { min-height: 46px; margin-top: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  .wst-tk-overlay,
  .wst-tk-sheet,
  .wst-tk-title-count.is-animated,
  .wst-tk-milestone.is-current > span,
  .wst-tk-celebration,
  .wst-tk-celebration__veil,
  .wst-tk-celebration__light-field,
  .wst-tk-celebration__impact-ring,
  .wst-tk-celebration__hero-anchor,
  .wst-tk-celebration__mark,
  .wst-tk-celebration__inner-shell,
  .wst-tk-celebration__ribbon,
  .wst-tk-celebration__count,
  .wst-tk-celebration__particles i {
    animation: none !important;
    transition: none !important;
  }

  .wst-tk-celebration__impact-ring,
  .wst-tk-celebration__ignition,
  .wst-tk-celebration__particles { display: none; }
}
