/* Shared tokens, the phone, chat bubbles and every animated demo.
   Pages add their own type and layout in a.css / note.css. */

:root {
  --bg: #ffffff;
  --fg: #17171c;
  --muted: #55555f;
  --subtle: #8a8a94;
  --line: #e6e6ea;
  --panel: #f6f6f8;
  --card: #ffffff;
  --blue: #0a84ff;
  --green: #30d158;
  --red: #ff3b30;
  --orange: #f97316;
  --purple: #8250df;

  /* The app inside the phone (Loop, a habit app) */
  --p-bg: #ffffff;
  --p-fg: #000000;
  --p-in: #e9e9eb;
  --p-line: #eeeef0;
  --p-card: #f4f4f6;
  --p-muted: #8a8a94;
  --bezel: #17171c;
  --glass: rgb(255 255 255 / 0.72);
  --glass-edge:
    0 0 0 0.5px rgb(0 0 0 / 0.07),
    0 6px 18px rgb(0 0 0 / 0.08),
    inset 0 1px 1px rgb(255 255 255 / 0.9),
    inset 0 -1px 1px rgb(0 0 0 / 0.03);

  --ease: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-io: cubic-bezier(0.77, 0, 0.175, 1);
  --sans: "Inter", system-ui, -apple-system, sans-serif;
  --display: "Inter Tight", "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --serif: "Newsreader", Georgia, serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0b0e;
    --fg: #f4f4f6;
    --muted: #a1a1aa;
    --subtle: #71717a;
    --line: #26262c;
    --panel: #131317;
    --card: #17171b;
    --p-bg: #000000;
    --p-fg: #ffffff;
    --p-in: #26252a;
    --p-line: #1c1c1f;
    --p-card: #1c1c1e;
    --p-muted: #8e8e93;
    --bezel: #3a3a40;
    --glass: rgb(44 44 48 / 0.72);
    --glass-edge:
      0 0 0 0.5px rgb(255 255 255 / 0.1),
      0 6px 18px rgb(0 0 0 / 0.4),
      inset 0 1px 1px rgb(255 255 255 / 0.14),
      inset 0 -1px 1px rgb(0 0 0 / 0.2);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img,
svg {
  display: block;
}
[hidden] {
  display: none !important;
}
a {
  color: inherit;
}
button {
  font: inherit;
  color: inherit;
}
:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

/* ---------- Phone ---------------------------------------------------------- */

.phone {
  --w: 340px;
  position: relative;
  width: var(--w);
  max-width: 100%;
  aspect-ratio: 390 / 800;
  border-radius: calc(var(--w) * 0.14);
  box-shadow:
    0 0 0 calc(var(--w) * 0.026) var(--bezel),
    0 30px 60px rgb(0 0 0 / 0.16);
  overflow: hidden;
  flex-shrink: 0;
  isolation: isolate;
  background: var(--p-bg);
}
.screen {
  position: absolute;
  top: 0;
  left: 0;
  width: 390px;
  height: 800px;
  transform: scale(var(--s, 0.87));
  transform-origin: 0 0;
  background: var(--p-bg);
  color: var(--p-fg);
  font-family: var(--sans);
  overflow: hidden;
}
.view {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  transition:
    opacity 0.35s var(--ease),
    transform 0.45s var(--ease);
}
.view.off {
  opacity: 0;
  transform: scale(0.97);
  pointer-events: none;
}
.status {
  height: 54px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 30px 0 44px;
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.01em;
}
.status .time {
  border-radius: 999px;
  padding: 1px 0;
  transition:
    background 0.3s,
    padding 0.3s,
    color 0.3s;
}
.status .time.rec {
  background: var(--red);
  color: #fff;
  padding: 1px 10px;
  margin-left: -10px;
}
.status .time.live {
  background: var(--green);
  color: #fff;
  padding: 1px 10px;
  margin-left: -10px;
}
.status svg {
  fill: currentColor;
}
.navbar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: start;
  padding: 0 16px 8px;
  flex-shrink: 0;
  position: relative;
  z-index: 3;
}
.navbar::after {
  /* the thread fades out under the glass */
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  height: 22px;
  background: linear-gradient(var(--p-bg), transparent);
  pointer-events: none;
}
.navbar .who {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.navbar .who .avatar {
  width: 44px;
  height: 44px;
  font-size: 18px;
  position: relative;
  z-index: 1;
}
.gname,
.gbtn,
.plus,
.field {
  background: var(--glass);
  -webkit-backdrop-filter: blur(14px) saturate(1.8);
  backdrop-filter: blur(14px) saturate(1.8);
  box-shadow: var(--glass-edge);
}
.gname {
  margin-top: -6px;
  padding: 4px 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.gname::after {
  content: " ›";
  color: var(--p-muted);
  font-weight: 500;
}
.gbtn {
  justify-self: end;
  margin-top: 4px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--p-fg);
}
.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--orange);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 15px;
}

.thread {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 6px;
  padding: 10px 14px 6px;
  overflow: hidden;
  min-height: 0;
}
.thread > * {
  flex-shrink: 0;
}
.stamp {
  align-self: center;
  font-size: 11px;
  color: var(--p-muted);
  padding: 4px 0 6px;
}
.stamp b {
  font-weight: 600;
}
.b {
  max-width: 272px;
  padding: 8px 13px;
  border-radius: 18px;
  font-size: 16px;
  line-height: 21px;
}
.b.me {
  align-self: flex-end;
  background: var(--blue);
  color: #fff;
}
.b.them {
  align-self: flex-start;
  background: var(--p-in);
  color: var(--p-fg);
}
.b.them + .b.me,
.b.me + .b.them {
  margin-top: 6px;
}
.cap {
  font-size: 11px;
  color: var(--p-muted);
  padding: 0 8px;
}
.cap.r {
  align-self: flex-end;
}
.cap.l {
  align-self: flex-start;
}
.sys {
  align-self: center;
  font-size: 12px;
  color: var(--p-muted);
  padding: 6px 0;
}
.typing {
  align-self: flex-start;
  background: var(--p-in);
  border-radius: 18px;
  padding: 12px 14px;
  display: flex;
  gap: 4px;
}
.typing i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--p-muted);
  animation: blink 1.2s infinite;
}
.typing i:nth-child(2) {
  animation-delay: 0.18s;
}
.typing i:nth-child(3) {
  animation-delay: 0.36s;
}
@keyframes blink {
  0%,
  60%,
  100% {
    opacity: 0.35;
  }
  30% {
    opacity: 1;
  }
}

/* Elements a demo reveals: hidden until .in */
.pop {
  opacity: 0;
  transform: translateY(10px) scale(0.96);
  transition:
    opacity 0.32s var(--ease),
    transform 0.42s var(--ease);
}
.b.me.pop {
  transform-origin: 100% 100%;
}
.b.them.pop,
.typing.pop {
  transform-origin: 0 100%;
}
.pop.in {
  opacity: 1;
  transform: none;
}
.fade {
  opacity: 0;
  transition: opacity 0.4s var(--ease);
}
.fade.in {
  opacity: 1;
}

.compose {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px 28px;
  flex-shrink: 0;
}
.plus {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--p-fg);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition:
    transform 0.16s var(--ease),
    background 0.2s,
    color 0.2s;
}
.plus.open {
  background: var(--blue);
  color: #fff;
  transform: rotate(45deg);
}
.field {
  flex: 1;
  min-height: 38px;
  border-radius: 19px;
  padding: 9px 42px 9px 16px;
  font-size: 16px;
  line-height: 20px;
  color: var(--p-muted);
  position: relative;
}
.field.has {
  color: var(--p-fg);
}
.send {
  position: absolute;
  right: 5px;
  bottom: 5px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue);
  display: grid;
  place-items: center;
  opacity: 0;
  transform: scale(0.6);
  transition:
    opacity 0.2s var(--ease),
    transform 0.25s var(--ease);
}
.field.has .send {
  opacity: 1;
  transform: none;
}

/* The finger that taps through demos */
.finger {
  position: absolute;
  left: 0;
  top: 0;
  width: 46px;
  height: 46px;
  margin: -23px 0 0 -23px;
  border-radius: 50%;
  background: rgb(120 120 128 / 0.32);
  border: 2px solid rgb(255 255 255 / 0.7);
  box-shadow: 0 4px 14px rgb(0 0 0 / 0.18);
  opacity: 0;
  z-index: 50;
  pointer-events: none;
  transition:
    transform 0.6s var(--ease-io),
    opacity 0.25s;
}
.finger.on {
  opacity: 1;
}
.finger.press {
  transition:
    transform 0.12s var(--ease),
    opacity 0.25s;
}
.pressed {
  transform: scale(0.94) !important;
  filter: brightness(0.92);
  transition: transform 0.12s var(--ease) !important;
}

/* Help card (hero) */
.helpcard {
  align-self: flex-start;
  width: 270px;
  border: 1px solid var(--p-line);
  border-radius: 18px;
  overflow: hidden;
  background: var(--p-bg);
}
.helpcard .shot {
  background: var(--p-card);
  height: 112px;
  display: flex;
  justify-content: center;
  align-items: flex-end;
}
.helpcard .mini {
  width: 150px;
  height: 98px;
  background: var(--p-bg);
  border: 1px solid var(--p-line);
  border-bottom: 0;
  border-radius: 12px 12px 0 0;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.mini b {
  font-size: 9px;
}
.bar {
  height: 7px;
  border-radius: 4px;
  background: var(--p-card);
}
.mini .hl {
  border: 1.5px solid var(--blue);
  background: color-mix(in srgb, var(--blue) 10%, var(--p-bg));
  border-radius: 6px;
  padding: 4px 6px;
  font-size: 8px;
  font-weight: 600;
  color: var(--blue);
  display: flex;
  justify-content: space-between;
}
.helpcard .txt {
  padding: 12px 14px 10px;
}
.helpcard .txt b {
  display: block;
  font-size: 15px;
  margin-bottom: 4px;
}
.helpcard .txt span {
  font-size: 13px;
  line-height: 18px;
  color: var(--p-muted);
}
.helpcard .acts {
  display: flex;
  border-top: 1px solid var(--p-line);
}
.helpcard .acts span {
  flex: 1;
  text-align: center;
  padding: 11px 0;
  color: var(--blue);
  font-size: 15px;
  font-weight: 600;
}
.helpcard .acts span + span {
  border-left: 1px solid var(--p-line);
  font-weight: 400;
}

/* Action card (refund) */
.action {
  align-self: flex-start;
  width: 260px;
  border-radius: 18px;
  border: 1px solid var(--p-line);
  overflow: hidden;
  background: var(--p-bg);
}
.action .top {
  padding: 12px 14px;
  display: flex;
  gap: 10px;
  align-items: center;
}
.action .ic {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--p-card);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.action .top b {
  display: block;
  font-size: 15px;
}
.action .top span {
  font-size: 13px;
  color: var(--p-muted);
}
.action .btn {
  display: block;
  border: 0;
  margin: 0 12px 12px;
  border-radius: 12px;
  background: var(--blue);
  color: #fff;
  text-align: center;
  padding: 10px;
  font-weight: 600;
  font-size: 15px;
  transition:
    background 0.3s,
    color 0.3s;
}
.action .btn.done {
  background: color-mix(in srgb, var(--green) 16%, var(--p-bg));
  color: #1f9a45;
}
.who-line {
  align-self: flex-start;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--p-muted);
  padding: 4px 6px 0;
}
.who-line .face {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(160deg, #c9a889, #9a7457);
  object-fit: cover;
}

/* Attach menu + video bubble (recording) */
.menu {
  position: absolute;
  left: 12px;
  bottom: 84px;
  width: 250px;
  border-radius: 16px;
  background: color-mix(in srgb, var(--p-bg) 94%, transparent);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow:
    0 12px 40px rgb(0 0 0 / 0.2),
    0 0 0 0.5px rgb(0 0 0 / 0.12);
  overflow: hidden;
  transform-origin: 12% 100%;
  z-index: 10;
}
.menu.pop {
  transform: scale(0.85);
}
.menu.pop.in {
  transform: none;
}
.menu .row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  font-size: 16px;
  border-top: 0.5px solid var(--p-line);
}
.menu .row:first-child {
  border-top: 0;
}
.menu .row small {
  display: block;
  font-size: 12px;
  color: var(--p-muted);
}
.menu .dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--red);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.menu .dot::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
}
.menu svg {
  stroke: var(--blue);
  fill: none;
  stroke-width: 1.8;
  flex-shrink: 0;
}
.video {
  align-self: flex-end;
  width: 168px;
  height: 290px;
  border-radius: 18px;
  overflow: hidden;
  background: var(--p-card);
  border: 1px solid var(--p-line);
  position: relative;
  padding: 26px 12px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.video b {
  font-size: 15px;
  font-weight: 800;
}
.video .red {
  font-size: 8px;
  color: var(--red);
  font-weight: 600;
}
.video .bar {
  height: 14px;
  background: var(--p-bg);
}
.video .play {
  position: absolute;
  left: 58px;
  top: 118px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgb(23 23 28 / 0.55);
  display: grid;
  place-items: center;
}
.video .len {
  position: absolute;
  left: 8px;
  bottom: 8px;
  background: rgb(23 23 28 / 0.6);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  border-radius: 999px;
  padding: 3px 7px;
}

/* Loop's "Today" screen, shown while recording and during a call */
.app {
  padding: 4px 20px 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.app h4 {
  margin: 0;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 42px;
}
.app .sub {
  font-size: 15px;
  color: var(--p-muted);
}
.app .sub em {
  font-style: normal;
  color: var(--red);
  font-weight: 600;
}
.habits {
  background: var(--p-card);
  border-radius: 16px;
  padding: 0 16px;
}
.habit {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-bottom: 1px solid var(--p-line);
  font-size: 16px;
  position: relative;
}
.habit:last-child {
  border-bottom: 0;
}
.habit .chk {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid color-mix(in srgb, var(--p-muted) 50%, transparent);
  flex-shrink: 0;
  transition:
    background 0.25s,
    border-color 0.25s;
}
.habit .chk.on {
  background: var(--orange);
  border-color: var(--orange);
}
.habit .name {
  flex: 1;
}
.habit .more {
  width: 30px;
  text-align: center;
  color: var(--p-muted);
  font-size: 18px;
  line-height: 18px;
}
.mask {
  font-size: 13px;
  color: var(--p-muted);
  border-radius: 6px;
  padding: 3px 10px;
  background: repeating-linear-gradient(45deg, var(--p-line) 0 4px, var(--p-card) 4px 8px);
}
.week {
  background: var(--p-card);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.week b {
  font-size: 15px;
}
.bars {
  height: 80px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}
.bars i {
  width: 28px;
  border-radius: 6px;
  background: var(--orange);
}
.bars i.no {
  background: color-mix(in srgb, var(--p-muted) 25%, transparent);
}
.recbar {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 38px;
  border-radius: 999px;
  background: rgb(23 23 28 / 0.92);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 8px 8px 18px;
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.25);
}
.recbar .t {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.recbar .t::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--red);
  animation: blink 1.4s infinite;
}
.recbar small {
  color: #a1a1aa;
  font-weight: 400;
  font-size: 13px;
}
.recbar .stop {
  background: #fff;
  color: #17171c;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 600;
  font-size: 15px;
}
.toast {
  position: absolute;
  left: 50%;
  top: 420px;
  width: 290px;
  margin-left: -145px;
  border-radius: 14px;
  background: var(--p-bg);
  box-shadow:
    0 8px 28px rgb(0 0 0 / 0.14),
    0 0 0 0.5px rgb(0 0 0 / 0.1);
  padding: 12px 16px;
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 13px;
  line-height: 18px;
  z-index: 5;
}
.toast svg {
  stroke: var(--blue);
  fill: none;
  stroke-width: 1.6;
  flex-shrink: 0;
}
.popmenu {
  position: absolute;
  right: 22px;
  width: 190px;
  border-radius: 14px;
  background: var(--p-bg);
  box-shadow:
    0 10px 30px rgb(0 0 0 / 0.18),
    0 0 0 0.5px rgb(0 0 0 / 0.1);
  font-size: 15px;
  z-index: 6;
  transform-origin: 90% 0;
}
.popmenu div {
  padding: 11px 14px;
  border-top: 0.5px solid var(--p-line);
}
.popmenu div:first-child {
  border-top: 0;
}
.popmenu .dis {
  color: var(--p-muted);
}

/* Calls */
.incoming {
  background: #11151b;
  color: #fff;
  align-items: center;
}
.incoming .poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
  animation: drift 12s ease-in-out infinite alternate;
}
.incoming .shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgb(0 0 0 / 0.55) 0%, rgb(0 0 0 / 0) 34%),
    linear-gradient(0deg, rgb(0 0 0 / 0.78) 0%, rgb(0 0 0 / 0.25) 36%, rgb(0 0 0 / 0) 52%);
}
.incoming > :not(.poster, .shade) {
  position: relative;
}
.incoming .status {
  align-self: stretch;
  color: #fff;
}
.ihead {
  align-self: stretch;
  padding: 18px 26px 0;
  text-shadow: 0 1px 12px rgb(0 0 0 / 0.25);
}
.incoming .kind {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 500;
  color: rgb(255 255 255 / 0.85);
}
.appicon {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: linear-gradient(160deg, #ff9a3c, #f2541b);
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 800;
  color: #fff;
}
.incoming .caller {
  font-family: var(--display);
  font-size: 64px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-top: 10px;
}
.incoming .ctx {
  font-size: 15px;
  color: rgb(255 255 255 / 0.8);
  margin-top: 8px;
}
@keyframes drift {
  from {
    transform: scale(1.02) translate(0, 0);
  }
  to {
    transform: scale(1.07) translate(-1.2%, 0.8%);
  }
}
.incoming .privacy {
  margin-top: auto;
  font-size: 13px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgb(255 255 255 / 0.16);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  display: flex;
  gap: 8px;
  align-items: center;
}
.callbtns {
  display: flex;
  gap: 90px;
  margin: 30px 0 64px;
}
.callbtns > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-size: 15px;
}
.callbtns .c {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.callbtns .dec {
  background: var(--red);
}
.callbtns .acc {
  background: var(--green);
  animation: nudge 1.6s var(--ease) infinite;
}
@keyframes nudge {
  0%,
  60%,
  100% {
    transform: translateY(0);
  }
  30% {
    transform: translateY(-6px);
  }
}
.pip {
  position: absolute;
  right: 14px;
  top: 58px;
  width: 104px;
  height: 140px;
  border-radius: 18px;
  background: #2c3a4a;
  box-shadow: 0 10px 28px rgb(0 0 0 / 0.3);
  overflow: hidden;
  z-index: 4;
  outline: 3px solid transparent;
  outline-offset: -3px;
  transition: outline-color 0.3s;
}
.pip img,
.cam .vid {
  width: 100%;
  height: 100%;
  object-fit: cover;
  animation: drift 10s ease-in-out infinite alternate;
}
.pip.talk,
.cam.talk {
  outline-color: var(--green);
}
.pip span {
  position: absolute;
  left: 8px;
  bottom: 6px;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-shadow: 0 1px 4px rgb(0 0 0 / 0.5);
}
.draw {
  position: absolute;
  z-index: 3;
  pointer-events: none;
  overflow: visible;
}
.draw path {
  fill: none;
  stroke: var(--blue);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
.draw.in path {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 0.9s var(--ease-io);
}
.note {
  position: absolute;
  z-index: 4;
  width: 236px;
  display: flex;
  gap: 8px;
  align-items: flex-start;
  background: var(--blue);
  color: #fff;
  border-radius: 16px 4px 16px 16px;
  padding: 10px 12px;
  font-size: 15px;
  line-height: 20px;
  box-shadow: 0 10px 24px rgb(10 132 255 / 0.3);
}
.note img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 1.5px solid rgb(255 255 255 / 0.7);
}
.note small {
  display: block;
  font-size: 12px;
  font-weight: 600;
  opacity: 0.8;
}
.callbar {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 30px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.sharing {
  background: color-mix(in srgb, var(--red) 14%, var(--p-bg));
  color: #d70015;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  font-variant-numeric: tabular-nums;
}
.sharing::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
}
.ctrls {
  width: 100%;
  display: flex;
  justify-content: space-between;
  background: rgb(30 30 36 / 0.88);
  border-radius: 28px;
  padding: 10px 14px;
}
.ctrls span {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.14);
  display: grid;
  place-items: center;
}
.ctrls span.on {
  background: #fff;
}
.ctrls span.end {
  width: 64px;
  border-radius: 24px;
  background: var(--red);
}
.ctrls svg {
  stroke: #fff;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ctrls .on svg {
  stroke: #17171c;
}
.callrow {
  align-self: center;
  display: flex;
  gap: 10px;
  align-items: center;
  background: var(--p-card);
  border-radius: 16px;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 500;
}
.callrow img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
}
.callrow .v {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--green);
  display: grid;
  place-items: center;
  margin-left: 6px;
}
.callrow small {
  display: block;
  color: var(--p-muted);
  font-size: 12px;
  font-weight: 400;
}

/* The web inbox call window (team side) */
.web {
  width: 100%;
  max-width: 780px;
  border-radius: 14px;
  overflow: hidden;
  background: var(--card);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fg) 10%, transparent),
    0 40px 80px rgb(0 0 0 / 0.14);
  font-family: var(--sans);
  color: var(--fg);
  position: relative;
}
.web .chrome {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
.web .chrome i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ff5f57;
}
.web .chrome i:nth-child(2) {
  background: #febc2e;
}
.web .chrome i:nth-child(3) {
  background: #28c840;
}
.web .chrome span {
  margin: 0 auto;
  font-size: 12px;
  color: var(--subtle);
  background: var(--card);
  border-radius: 6px;
  padding: 3px 40px;
}
.web .whead {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.web .whead .av {
  width: 34px;
  height: 34px;
  border-radius: 50%;
}
.web .whead .who {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}
.web .whead b {
  font-weight: 600;
}
.web .whead .who span {
  color: var(--subtle);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.livepill {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--subtle);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 10px;
  transition:
    color 0.3s,
    border-color 0.3s;
  white-space: nowrap;
}
.livepill i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--subtle);
}
.livepill.on {
  color: #1f9d48;
  border-color: color-mix(in srgb, var(--green) 50%, transparent);
}
.livepill.on i {
  background: var(--green);
  animation: livedot 1.4s ease-in-out infinite;
}
@keyframes livedot {
  50% {
    opacity: 0.35;
  }
}
.livepill .clock {
  font-family: var(--mono);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.web .body {
  display: grid;
  grid-template-columns: 40% 1fr;
  min-height: 380px;
}
.web .left {
  border-right: 1px solid var(--line);
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  position: relative;
  background: color-mix(in srgb, var(--panel) 60%, var(--card));
}
.web .chip {
  align-self: flex-start;
  font-size: 11px;
  color: var(--subtle);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 9px;
  background: var(--card);
}
.mirror {
  width: 156px;
  aspect-ratio: 390 / 800;
  border-radius: 24px;
  border: 5px solid var(--bezel);
  background: var(--p-bg);
  color: var(--p-fg);
  padding: 16px 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.12);
}
.mirror .wait {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  text-align: center;
  font-size: 11px;
  color: var(--p-muted);
  background: var(--p-bg);
  transition: opacity 0.4s;
  padding: 14px;
}
.mirror b {
  font-size: 15px;
  font-weight: 800;
}
.mirror small {
  font-size: 8px;
  color: var(--p-muted);
}
.mirror .mrow {
  display: flex;
  gap: 5px;
  align-items: center;
  font-size: 8px;
  background: var(--p-card);
  border-radius: 6px;
  padding: 5px 6px;
}
.mirror .mrow i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--orange);
}
.mirror .mrow i.o {
  background: none;
  border: 1px solid var(--p-muted);
}
.mirror .mrow .dots {
  margin-left: auto;
  color: var(--p-muted);
}
.tools {
  margin-top: auto;
  align-self: stretch;
  display: flex;
  justify-content: center;
  gap: 6px;
  font-size: 11px;
}
.tools span {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 999px;
  padding: 4px 10px;
  transition:
    background 0.2s,
    color 0.2s;
}
.tools span.on {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}
.web .right {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.cam {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: #1c1c22;
  outline: 3px solid transparent;
  outline-offset: -3px;
  transition: outline-color 0.3s;
}
.cam.them {
  margin: 12px 12px 0;
  aspect-ratio: 4 / 3;
}
.cam.them > .vid {
  object-position: 50% 30%;
}
.cam.me {
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 28%;
  aspect-ratio: 4 / 3;
  border-radius: 8px;
  box-shadow: 0 6px 16px rgb(0 0 0 / 0.35);
  z-index: 2;
}
.cam .nm {
  position: absolute;
  left: 10px;
  bottom: 8px;
  display: flex;
  gap: 6px;
  align-items: center;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-shadow: 0 1px 6px rgb(0 0 0 / 0.5);
  z-index: 1;
}
.cam.me .nm {
  left: 6px;
  bottom: 4px;
  font-size: 10px;
}
.lvl {
  display: flex;
  gap: 2px;
  align-items: center;
  height: 12px;
}
.lvl i {
  width: 3px;
  height: 4px;
  border-radius: 2px;
  background: #fff;
}
.cam.talk .lvl i {
  animation: level 0.5s ease-in-out infinite alternate;
}
.cam.talk .lvl i:nth-child(2) {
  animation-delay: 0.15s;
}
.cam.talk .lvl i:nth-child(3) {
  animation-delay: 0.3s;
}
@keyframes level {
  to {
    height: 12px;
  }
}
.ringing {
  position: absolute;
  inset: 0;
  z-index: 3;
  background: #1c1c22;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #c7c7cc;
  font-size: 12px;
  transition: opacity 0.5s var(--ease);
}
.ringing img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  animation: ringpulse 1.6s var(--ease) infinite;
}
@keyframes ringpulse {
  0% {
    box-shadow: 0 0 0 0 rgb(255 255 255 / 0.35);
  }
  100% {
    box-shadow: 0 0 0 18px rgb(255 255 255 / 0);
  }
}
.cam .ended {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: rgb(18 18 22 / 0.7);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: #fff;
  font-size: 12px;
  text-align: center;
  padding: 12px;
}
.cam .ended b {
  font-size: 15px;
  font-weight: 600;
}
.cam .ended span {
  color: rgb(255 255 255 / 0.7);
}
.ringing.gone {
  opacity: 0;
}
.notes {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  line-height: 18px;
  color: var(--muted);
}
.notes b {
  color: var(--fg);
  font-weight: 600;
  margin-right: 4px;
}
.notes .h {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--subtle);
}
.notes .lk {
  color: var(--blue);
}
.web .foot {
  border-top: 1px solid var(--line);
  padding: 10px;
  display: flex;
  justify-content: center;
  gap: 8px;
}
.web .foot span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--panel);
}
.web .foot .endb {
  width: auto;
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  padding: 0 14px;
  font-size: 12px;
  font-weight: 600;
  display: grid;
  place-items: center;
}
.cursor {
  position: absolute;
  width: 18px;
  height: 18px;
  z-index: 6;
  left: 0;
  top: 0;
  opacity: 0;
  transition:
    transform 0.7s var(--ease-io),
    opacity 0.3s;
}
.cursor.on {
  opacity: 1;
}

/* Loop habit icons */
.habit .ico {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  background: var(--c);
}
.habit .ico svg {
  stroke: #fff;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Survey card */
.survey {
  align-self: flex-start;
  width: 280px;
  border-radius: 18px;
  background: var(--p-in);
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.survey p {
  margin: 0;
  font-size: 16px;
  line-height: 21px;
}
.opts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.opts span {
  border-radius: 999px;
  background: var(--p-bg);
  padding: 7px 12px;
  font-size: 14px;
  transition:
    background 0.25s,
    color 0.25s;
}
.opts span.sel {
  background: var(--blue);
  color: #fff;
}
.invite {
  align-self: flex-start;
  width: 270px;
  border-radius: 18px;
  border: 1px solid var(--p-line);
  padding: 14px;
  display: flex;
  gap: 12px;
  align-items: center;
  background: var(--p-bg);
}
.invite .mic {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--blue);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.invite b {
  display: block;
  font-size: 15px;
}
.invite span {
  font-size: 13px;
  color: var(--p-muted);
  line-height: 18px;
}

/* ---------- Insights: what to fix ----------------------------------------- */
.rank {
  background: var(--card);
  border-radius: 16px;
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fg) 9%, transparent),
    0 24px 50px rgb(0 0 0 / 0.07);
  overflow: hidden;
  position: relative;
}
.rank .rh {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  gap: 12px;
}
.rank .rh b {
  font-size: 15px;
}
.rank .rh span {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--subtle);
}
.rrow {
  display: grid;
  grid-template-columns: 22px 1fr 96px auto;
  gap: 4px 14px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
  align-items: center;
  transition: background 0.4s;
}
.rrow:last-of-type {
  border-bottom: 0;
}
.rrow.hot {
  background: color-mix(in srgb, var(--blue) 6%, transparent);
}
.rrow .n {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--subtle);
}
.rrow .t {
  font-size: 15px;
  font-weight: 500;
}
.rrow .t small {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--subtle);
  margin-left: 8px;
  font-weight: 400;
}
.rrow .m {
  font-family: var(--mono);
  font-size: 14px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.rrow .meta {
  grid-column: 2 / 5;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--subtle);
}
.rrow .track {
  flex: 1;
  height: 4px;
  border-radius: 2px;
  background: var(--line);
  overflow: hidden;
}
.rrow .track i {
  display: block;
  height: 100%;
  width: 100%;
  background: var(--blue);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 1.1s var(--ease);
}
.src {
  display: flex;
  gap: 4px;
}
.src em {
  font-style: normal;
  font-size: 10px;
  border-radius: 999px;
  padding: 2px 7px;
  background: var(--panel);
  color: var(--muted);
  white-space: nowrap;
}
.rank .ship {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}
.rank .ship .go {
  border-radius: 999px;
  background: var(--fg);
  color: var(--bg);
  padding: 9px 14px;
  font-weight: 600;
  font-size: 13px;
  white-space: nowrap;
  transition: transform 0.16s var(--ease);
}
.rank .sent {
  position: absolute;
  left: 50%;
  bottom: 66px;
  transform: translateX(-50%);
  background: var(--fg);
  color: var(--bg);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  white-space: nowrap;
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.2);
}
.rank .sent.pop {
  transform: translate(-50%, 10px);
}
.rank .sent.pop.in {
  transform: translate(-50%, 0);
}

/* ---------- Bug to fix: four beats --------------------------------------- */
.loop4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  position: relative;
}
.beat {
  border-radius: 16px;
  padding: 18px;
  background: var(--beat-bg, var(--card));
  border: 1px solid var(--beat-line, var(--line));
  display: flex;
  flex-direction: column;
  gap: 14px;
  opacity: 0.4;
  transition:
    opacity 0.5s var(--ease),
    border-color 0.5s;
  min-height: 250px;
}
.beat.on {
  opacity: 1;
  border-color: var(--blue);
}
.beat .k {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--beat-sub, var(--subtle));
}
.beat h5 {
  margin: 0;
  font-size: 17px;
  line-height: 22px;
  font-weight: 600;
}
.beat .mb {
  border-radius: 16px;
  padding: 9px 12px;
  font-size: 13px;
  line-height: 18px;
}
.beat .mb.me {
  background: var(--blue);
  color: #fff;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.beat .mb.them {
  background: var(--beat-in, var(--panel));
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}
.brief {
  font-family: var(--mono);
  font-size: 11px;
  line-height: 17px;
  color: var(--beat-sub, var(--muted));
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.brief b {
  color: var(--beat-fg, var(--fg));
  font-weight: 600;
}
.brief span {
  opacity: 0;
  transform: translateX(-4px);
  transition:
    opacity 0.3s var(--ease),
    transform 0.3s var(--ease);
}
.beat.on .brief span {
  opacity: 1;
  transform: none;
}
.beat.on .brief span:nth-child(2) {
  transition-delay: 0.12s;
}
.beat.on .brief span:nth-child(3) {
  transition-delay: 0.22s;
}
.beat.on .brief span:nth-child(4) {
  transition-delay: 0.3s;
}
.beat.on .brief span:nth-child(5) {
  transition-delay: 0.36s;
}
.pr {
  border-radius: 12px;
  border: 1px solid var(--beat-line, var(--line));
  padding: 12px;
  font-size: 13px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pr .st {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 600;
  background: #238636;
  color: #fff;
  transition: background 0.4s;
}
.pr .st.merged {
  background: var(--purple);
}
.pr .ck {
  font-size: 12px;
  color: var(--beat-sub, var(--subtle));
  font-family: var(--mono);
}

/* ---------- Install terminal ---------------------------------------------- */
.term {
  border-radius: 14px;
  background: #0f0f12;
  color: #e4e4e7;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 21px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgb(255 255 255 / 0.06),
    0 24px 50px rgb(0 0 0 / 0.18);
}
.term .bar3 {
  display: flex;
  gap: 6px;
  padding: 12px 14px;
  border-bottom: 1px solid #222228;
  align-items: center;
}
.term .bar3 i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #3a3a40;
}
.term .bar3 span {
  margin-left: 8px;
  font-size: 11px;
  color: #71717a;
}
.term pre {
  margin: 0;
  padding: 16px 18px 20px;
  white-space: pre-wrap;
  min-height: 250px;
  font: inherit;
}
.term .p {
  color: #71717a;
}
.term .ok {
  color: #4ade80;
}
.term .dim {
  color: #a1a1aa;
}
.caret {
  display: inline-block;
  width: 7px;
  height: 15px;
  background: #e4e4e7;
  vertical-align: -2px;
  animation: blink 1s steps(1) infinite;
}

/* ---------- Animation notes off / reduced motion ------------------------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
}

/* ---------- Feedback ------------------------------------------------------ */
.fb {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.fb .btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.fb button {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 999px;
  padding: 13px 22px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition:
    transform 0.16s var(--ease),
    background 0.2s,
    border-color 0.2s;
}
.fb button:active {
  transform: scale(0.97);
}
.fb button.yes {
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
}
.fb button.picked {
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 30%, transparent);
}
.fb textarea {
  width: 100%;
  min-height: 96px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--fg);
  font: inherit;
  font-size: 16px;
  padding: 12px 14px;
  resize: vertical;
}
.fb .more {
  display: none;
  flex-direction: column;
  gap: 10px;
}
.fb.asked .more {
  display: flex;
}
.fb .send {
  position: static;
  opacity: 1;
  transform: none;
  width: auto;
  height: auto;
  align-self: flex-start;
  background: var(--fg);
  color: var(--bg);
  border-color: var(--fg);
}
.fb .thanks {
  display: none;
  font-size: 17px;
}
.fb.done .thanks {
  display: block;
}
.fb.done .more,
.fb.done .btns {
  display: none;
}
.fb small {
  color: var(--subtle);
  font-size: 13px;
}

.rank,
.loop4,
.term {
  font-family: var(--sans);
}
.term {
  font-family: var(--mono);
}

/* ---------- Theming demo ---------------------------------------------------- */
.themer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}
.tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  font-family: var(--sans);
}
.tabs span {
  display: flex;
  flex-direction: column;
  align-items: center;
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 12px;
  padding: 6px 12px;
  font-size: 11px;
  color: var(--subtle);
  transition:
    border-color 0.3s,
    color 0.3s,
    transform 0.3s var(--ease);
}
.tabs span b {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}
.tabs span.on {
  border-color: var(--blue);
  color: var(--blue);
  transform: translateY(-2px);
}
.tabs span.on b {
  color: var(--fg);
}
.tview {
  --c: 0.5s var(--ease);
  background: var(--t-bg);
  color: var(--t-fg);
  transition:
    background var(--c),
    color var(--c);
}
.tview .status {
  color: var(--t-fg);
  transition: color var(--c);
}
.tnav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: start;
  padding: 0 16px 10px;
  max-height: 90px;
  overflow: hidden;
  transition:
    max-height 0.5s var(--ease),
    padding 0.5s var(--ease),
    opacity 0.3s;
}
.tnav.gone {
  max-height: 0;
  padding-bottom: 0;
  opacity: 0;
}
.tnav .who {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 12px;
}
.tnav .who b {
  font-weight: 600;
  font-family: var(--t-font);
  margin-top: -6px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--t-glass);
  box-shadow: var(--glass-edge);
}
.tav {
  position: relative;
  z-index: 1;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--t-mark);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 15px;
}
.tclose {
  position: absolute;
  right: 16px;
  top: 58px;
  z-index: 3;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--t-fg);
  display: grid;
  place-items: center;
  box-shadow: var(--glass-edge);
}
.tview {
  --t-glass: color-mix(in srgb, var(--t-fg) 6%, var(--t-bg));
}
.tview .tclose,
.tview .compose .plus,
.tview .field {
  background: var(--t-glass);
}
.tview .thread {
  font-family: var(--t-font);
  transition: opacity 0.25s;
}
.tview .thread.swap {
  opacity: 0;
}
.tview .thread > * {
  transition:
    opacity 0.35s var(--ease),
    transform 0.45s var(--ease);
}
.tview .thread > .tin {
  opacity: 0;
  transform: translateY(10px) scale(0.97);
}
.tview .b {
  font-size: var(--t-fs);
  font-weight: var(--t-fw);
  line-height: 1.32;
  border-radius: var(--t-r);
}
.tview .b.me {
  background: var(--t-out);
  color: var(--t-outfg);
}
.tview .b.them {
  background: var(--t-in);
  color: var(--t-infg);
}
.tview .stamp {
  color: var(--t-muted);
  font-family: var(--sans);
}
.tview .who-line {
  color: var(--t-muted);
  font-family: var(--sans);
}
.tview .who-line .face {
  width: 20px;
  height: 20px;
}
.tact {
  align-self: flex-start;
  width: 250px;
  border-radius: var(--t-r);
  border: 1px solid var(--t-line);
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 15px;
}
.tact b {
  color: var(--t-acc);
  font-weight: 600;
}
.tact small {
  color: var(--t-muted);
  font-size: 12px;
}
.tview .compose .plus {
  color: var(--t-fg);
}
.tview .field {
  border-radius: max(var(--t-r), 10px);
  color: var(--t-muted);
  font-family: var(--t-font);
  white-space: nowrap;
  overflow: hidden;
}
.tview .field.has {
  color: var(--t-fg);
}
.steps li code {
  display: block;
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.55;
  color: var(--muted);
  background: var(--panel);
  border-radius: 8px;
  padding: 8px 10px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* ---------- Moments demo ---------------------------------------------------- */
.moments {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}
.mapp {
  flex: 1;
  transition: opacity 0.25s;
}
.mapp.swap {
  opacity: 0;
}
.mscr.onb {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 32px 0;
  gap: 12px;
}
.mscr .art {
  position: relative;
  width: 180px;
  height: 180px;
  margin-bottom: 18px;
}
.mscr .art i {
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(160deg, #ffb066, #f2541b);
}
.mscr .art i:nth-child(1) {
  inset: 0;
  opacity: 0.18;
}
.mscr .art i:nth-child(2) {
  inset: 28px;
  opacity: 0.4;
}
.mscr .art i:nth-child(3) {
  inset: 58px;
}
.mscr h4,
.mapp .app h4 {
  margin: 0;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.mscr p {
  margin: 0;
  font-size: 16px;
  color: var(--p-muted);
  line-height: 1.4;
}
.mapp .cta {
  margin-top: 14px;
  align-self: stretch;
  text-align: center;
  background: var(--orange);
  color: #fff;
  font-weight: 600;
  font-size: 16px;
  border-radius: 14px;
  padding: 14px;
}
.mapp .cta.ghost {
  background: var(--p-card);
  color: var(--p-fg);
}
.mapp .cta.red {
  background: none;
  color: var(--red);
  margin-top: 4px;
}
.err {
  background: color-mix(in srgb, var(--red) 10%, var(--p-bg));
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 14px;
  line-height: 1.4;
  color: var(--p-muted);
  display: flex;
  flex-direction: column;
}
.err b {
  color: var(--red);
  font-size: 15px;
}
.err.shake {
  animation: shake 0.4s var(--ease);
}
@keyframes shake {
  25% {
    transform: translateX(-6px);
  }
  75% {
    transform: translateX(6px);
  }
}
.plan {
  background: var(--p-card);
  border-radius: 16px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 15px;
}
.plan b {
  font-size: 18px;
}
.plan small {
  color: var(--p-muted);
  font-size: 13px;
}
.mdim {
  position: absolute;
  inset: 0;
  background: rgb(0 0 0 / 0.28);
  opacity: 0;
  transition: opacity 0.35s;
  z-index: 4;
}
.mdim.in {
  opacity: 1;
}
.msheet {
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 8px;
  z-index: 5;
  background: var(--p-bg);
  border-radius: 34px;
  padding: 8px 14px 22px;
  box-shadow: 0 -10px 40px rgb(0 0 0 / 0.18);
  transform: translateY(110%);
  transition: transform 0.5s var(--ease);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.msheet.in {
  transform: none;
}
.grab {
  align-self: center;
  width: 36px;
  height: 5px;
  border-radius: 3px;
  background: color-mix(in srgb, var(--p-muted) 40%, transparent);
}
.mwho {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  padding: 4px 2px 2px;
}
.mwho .avatar {
  width: 26px;
  height: 26px;
  font-size: 12px;
}
.mwho small {
  color: var(--p-muted);
  font-size: 12px;
}
.mbody {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 40px;
}
.mbody .b {
  font-size: 15px;
  line-height: 20px;
}
.mchips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition:
    max-height 0.4s var(--ease),
    opacity 0.3s;
}
.mchips.in {
  max-height: 120px;
  opacity: 1;
}
.mchips.used {
  max-height: 0;
  opacity: 0;
}
.mchips span {
  border: 1.5px solid var(--blue);
  color: var(--blue);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 14px;
  font-weight: 500;
}
.mchips span.pressed,
.opts > div.pressed {
  background: var(--blue);
  color: #fff;
}
.mtoast {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 13px;
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 999px;
  padding: 7px 14px 7px 8px;
  opacity: 0;
  transform: translateY(-6px);
  transition:
    opacity 0.35s,
    transform 0.45s var(--ease);
  max-width: 100%;
}
.mtoast.in {
  opacity: 1;
  transform: none;
}
.mtoast span {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  background: var(--purple);
  border-radius: 999px;
  padding: 3px 8px;
}
.mtoast b {
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mapp .app {
  padding-top: 18px;
}
.opts {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 2px;
}
.opts > div {
  border: 1px solid var(--p-line);
  background: var(--p-card);
  border-radius: 14px;
  padding: 9px 12px;
  display: flex;
  flex-direction: column;
  font-size: 14px;
  transition: background 0.2s;
}
.opts > div b {
  font-weight: 600;
}
.opts > div small {
  color: var(--p-muted);
  font-size: 12px;
}
.opts > div.pressed small {
  color: rgb(255 255 255 / 0.8);
}
.opts .no {
  background: none;
  border: 0;
  text-align: center;
  color: var(--p-muted);
  padding: 4px;
}
.mtoast.saved span {
  background: #1f9d48;
}

/* Trends on the ranked list */
.trend {
  display: inline-block;
  margin-left: 8px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 999px;
  padding: 2px 8px;
  vertical-align: 1px;
  background: var(--panel);
  color: var(--subtle);
}
.trend.new {
  background: color-mix(in srgb, var(--purple) 14%, transparent);
  color: var(--purple);
}
.trend.up {
  background: color-mix(in srgb, var(--orange) 15%, transparent);
  color: #c2570c;
}
.trend.down {
  color: var(--subtle);
}
.spark {
  width: 96px;
  height: 24px;
  overflow: visible;
}
.spark polyline {
  fill: none;
  stroke: var(--subtle);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
.spark.new polyline {
  stroke: var(--purple);
}
.spark.up polyline {
  stroke: var(--orange);
}
.drawn .spark polyline {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.2s var(--ease-io);
}
@media (max-width: 560px) {
  .rrow {
    grid-template-columns: 22px 1fr auto;
  }
  .spark {
    display: none;
  }
  .rrow .meta {
    grid-column: 2 / 4;
  }
}

/* Weekly brief (email) */
.mail {
  border-radius: 16px;
  background: var(--card);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fg) 9%, transparent),
    0 24px 50px rgb(0 0 0 / 0.1);
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-family: var(--sans);
  color: var(--fg);
  min-height: 420px;
}
.mtop {
  display: flex;
  gap: 12px;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.mtop > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.mtop b {
  font-size: 16px;
}
.mtop small {
  font-size: 12px;
  color: var(--subtle);
}
.mfrom {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  border-radius: 10px;
  background: var(--blue);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
}
.mkpis {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.mkpis > div {
  background: var(--panel);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 12px;
  color: var(--subtle);
  display: flex;
  flex-direction: column;
}
.mkpis b {
  font-size: 20px;
  color: var(--fg);
  font-weight: 700;
  letter-spacing: -0.01em;
}
.msec h6 {
  margin: 0 0 4px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--subtle);
  display: flex;
  align-items: center;
  gap: 7px;
}
.msec h6 i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--subtle);
}
.msec h6 i.new {
  background: var(--purple);
}
.msec h6 i.up {
  background: var(--orange);
}
.msec h6 i.shift {
  background: var(--green);
}
.msec p {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--fg);
}
.msec p.q {
  font-style: italic;
  color: var(--muted);
}
.mcp-col .term pre {
  min-height: 340px;
}
@media (prefers-color-scheme: dark) {
  .msheet {
    background: #1c1c1e;
  }
  .msheet .b.them,
  .msheet .typing {
    background: #2c2c2e;
  }
  .opts > div {
    background: #2c2c2e;
    border-color: #3a3a3c;
  }
}

/* ---------- Team dashboard demo (canvas 1100 × 660, scaled to fit) -------- */
.dash {
  width: 100%;
  aspect-ratio: 1100 / 660;
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fg) 10%, transparent),
    0 40px 80px rgb(0 0 0 / 0.14);
  background: var(--card);
}
.dcanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 1100px;
  height: 660px;
  transform: scale(var(--ds, 1));
  transform-origin: 0 0;
  display: flex;
  flex-direction: column;
  font-family: var(--sans);
  color: var(--fg);
  font-size: 13px;
  --d-sub: color-mix(in srgb, var(--fg) 55%, transparent);
  --d-in: color-mix(in srgb, var(--fg) 7%, var(--card));
}
.dchrome {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 9px 14px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
}
.dchrome i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ff5f57;
}
.dchrome i:nth-child(2) {
  background: #febc2e;
}
.dchrome i:nth-child(3) {
  background: #28c840;
}
.dchrome span {
  margin: 0 auto;
  font-size: 12px;
  color: var(--subtle);
  background: var(--card);
  border-radius: 6px;
  padding: 3px 60px;
}
.dapp {
  flex: 1;
  display: flex;
  min-height: 0;
  position: relative;
}
.drail {
  width: 52px;
  flex-shrink: 0;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 12px 0;
  background: color-mix(in srgb, var(--panel) 60%, var(--card));
}
.dlogo {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: linear-gradient(160deg, #ff9a3c, #f2541b);
  color: #fff;
  font-weight: 800;
  display: grid;
  place-items: center;
  margin-bottom: 8px;
}
.ri {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  position: relative;
  color: var(--subtle);
  transition:
    background 0.25s,
    color 0.25s;
}
.ri svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ri.on {
  background: color-mix(in srgb, var(--blue) 12%, transparent);
  color: var(--blue);
}
.spk {
  fill: currentColor;
  stroke: none;
  flex-shrink: 0;
}
.ri .spk {
  fill: currentColor;
  width: 16px;
  height: 16px;
}
.badge {
  position: absolute;
  top: -3px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: var(--orange);
  color: #fff;
  font-size: 10px;
  display: grid;
  place-items: center;
  transform: scale(0);
  transition: transform 0.35s var(--ease);
}
.badge.in {
  transform: scale(1);
}
.dview {
  position: absolute;
  inset: 0 0 0 52px;
  display: flex;
  transition:
    opacity 0.35s var(--ease),
    transform 0.45s var(--ease);
}
.dview.off {
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
}
.dlist {
  width: 300px;
  flex-shrink: 0;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
}
.dtitle {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 16px 10px;
  font-size: 15px;
}
.dtitle .spk {
  color: var(--blue);
}
.dtitle span {
  margin-left: auto;
  font-size: 12px;
  color: var(--subtle);
}
.dtabs {
  display: flex;
  gap: 4px;
  padding: 0 10px 10px;
  border-bottom: 1px solid var(--line);
  font-size: 12px;
  color: var(--d-sub);
}
.dtabs span {
  padding: 4px 8px;
  border-radius: 7px;
}
.dtabs .on {
  background: var(--d-in);
  color: var(--fg);
  font-weight: 600;
}
.drow {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1px 8px;
  padding: 10px 16px;
  border-left: 2px solid transparent;
  max-height: 60px;
  overflow: hidden;
  transition:
    max-height 0.45s var(--ease),
    padding 0.45s var(--ease),
    opacity 0.3s,
    transform 0.45s var(--ease);
}
.drow b {
  font-weight: 600;
}
.drow span {
  grid-column: 1 / 3;
  color: var(--d-sub);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.drow small {
  grid-row: 1;
  grid-column: 2;
  font-size: 11px;
  color: var(--subtle);
}
.drow.res small {
  color: #1f9d48;
}
.drow.sel {
  background: color-mix(in srgb, var(--blue) 7%, transparent);
  border-left-color: var(--blue);
}
.drow.leave {
  max-height: 0;
  padding-block: 0;
  opacity: 0;
  transform: translateX(-30px);
}
.drow small.esc {
  color: #c2570c;
  font-weight: 600;
}
.newrow {
  animation: slidein 0.6s var(--ease) 0.2s both;
}
@keyframes slidein {
  from {
    opacity: 0;
    transform: translateY(-14px);
  }
}
.dthread {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.dhead {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
  min-height: 52px;
}
.dhead b {
  margin-right: auto;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 500;
  border-radius: 7px;
  padding: 4px 8px;
  background: var(--d-in);
  transition: opacity 0.3s;
}
.chip.ai .spk {
  color: var(--blue);
}
.chip.ai.gone {
  display: none;
}
.chip.esc {
  display: none;
  background: color-mix(in srgb, var(--orange) 15%, transparent);
  color: #c2570c;
}
.chip.esc.in {
  display: inline-flex;
}
.chip.open {
  color: var(--blue);
}
.chip.open.done {
  color: #1f9d48;
}
.kbtn {
  font-size: 12px;
  font-weight: 600;
  background: var(--fg);
  color: var(--bg);
  border-radius: 7px;
  padding: 4px 8px;
}
.kbtn kbd {
  font: inherit;
  opacity: 0.6;
  margin-left: 4px;
}
.dmsgs {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  padding: 16px 40px;
  overflow: hidden;
}
.dstamp,
.dsys {
  align-self: center;
  font-size: 11px;
  color: var(--subtle);
}
.dsys {
  color: #c2570c;
}
.db {
  max-width: 70%;
  padding: 8px 12px;
  border-radius: 16px;
  font-size: 13.5px;
  line-height: 1.4;
}
.db.them {
  align-self: flex-start;
  background: var(--d-in);
}
.dai {
  align-self: flex-end;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
  max-width: 70%;
}
.dai small {
  display: flex;
  gap: 4px;
  align-items: center;
  font-size: 11px;
  color: var(--subtle);
}
.dai small .spk {
  width: 10px;
  height: 10px;
  color: var(--blue);
}
.dai .db {
  max-width: none;
}
.db.me {
  background: var(--blue);
  color: #fff;
}
.hnote {
  border-radius: 12px;
  border: 1px solid color-mix(in srgb, #f59e0b 35%, transparent);
  background: color-mix(in srgb, #f59e0b 10%, var(--card));
  padding: 10px 14px;
  font-size: 13px;
  line-height: 1.45;
}
.hnote p {
  margin: 3px 0 0;
}
.hnote .hh {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 0 0 4px;
  font-size: 12px;
  color: #b45309;
}
.hnote .hh span {
  opacity: 0.8;
}
.dcompose {
  margin: 0 40px 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--subtle);
}
.dcompose .typing-on {
  color: var(--fg);
  font-family: var(--mono);
}
.dcompose .dsend {
  background: var(--blue);
  color: #fff;
  border-radius: 7px;
  padding: 4px 10px;
  font-size: 12px;
  font-weight: 600;
  opacity: 0.5;
}
.dside {
  width: 230px;
  flex-shrink: 0;
  border-left: 1px solid var(--line);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.dside > b {
  font-size: 15px;
}
.dside > small {
  color: var(--subtle);
  margin-bottom: 10px;
}
.dcard {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 9px 11px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin-bottom: 6px;
}
.dcard span {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--subtle);
  font-family: var(--mono);
}
.dcard small {
  color: var(--d-sub);
}
.devents {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 10px;
  font-size: 12px;
  margin-top: 6px;
}
.devents span {
  color: var(--subtle);
}
.drep {
  flex: 1;
  padding: 0 24px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.drep .dtitle {
  padding: 16px 0 0;
  font-size: 18px;
}
.dkpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.dkpis > div {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dkpis small {
  color: var(--subtle);
}
.dkpis b {
  font-size: 28px;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.dkpis i {
  font-style: normal;
  font-size: 11px;
  color: #1f9d48;
}
.dcharts {
  flex: 1;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 12px;
  min-height: 0;
}
.dbox {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.dbox > b {
  font-size: 14px;
}
.leg {
  display: flex;
  gap: 6px;
  align-items: center;
  font-size: 11px;
  color: var(--subtle);
  margin-top: -8px;
}
.leg i {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}
.leg i.ai,
.hbar i.ai {
  background: var(--blue);
}
.leg i.tm,
.hbar i.tm {
  background: var(--orange);
}
.hbar {
  display: grid;
  grid-template-columns: 110px 1fr 36px;
  gap: 10px;
  align-items: center;
  font-size: 12px;
}
.hbar .tr {
  display: flex;
  height: 12px;
  border-radius: 4px;
  overflow: hidden;
  background: var(--d-in);
}
.hbar i {
  width: 0;
  transition: width 1s var(--ease);
}
.drep.on .hbar i {
  width: var(--w);
}
.hbar small {
  color: var(--subtle);
  text-align: right;
}
.cols {
  flex: 1;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 10px;
}
.cols > div {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
}
.cols i {
  width: 100%;
  height: 0;
  border-radius: 5px 5px 2px 2px;
  background: var(--orange);
  position: relative;
  overflow: hidden;
  transition: height 1s var(--ease);
}
.cols em {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 81%;
  background: var(--blue);
}
.drep.on .cols i {
  height: var(--h);
}
.cols small {
  font-size: 11px;
  color: var(--subtle);
}
[data-demo="dash"] {
  width: 100%;
  justify-self: stretch;
}

/* ---------- Voice messages + any language --------------------------------- */

.lang {
  display: flex;
  gap: 28px;
  align-items: center;
  justify-content: center;
}
.lang .phone {
  --w: 330px;
}
.mic {
  position: absolute;
  right: 6px;
  bottom: 4px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: var(--p-muted);
}
.compose {
  position: relative;
}
.recbar {
  position: absolute;
  inset: 8px 14px 28px 60px;
  border-radius: 19px;
  background: var(--p-card);
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  opacity: 0;
  transform: scale(0.96);
  transition:
    opacity 0.25s,
    transform 0.3s var(--ease);
}
.recbar.in {
  opacity: 1;
  transform: none;
}
.recbar b {
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  color: var(--p-fg);
  font-weight: 500;
}
.rdot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--red);
  animation: livedot 1s steps(1) infinite;
}
.wave {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 1;
  height: 26px;
}
.wave i {
  width: 3px;
  border-radius: 2px;
  background: currentColor;
  opacity: 0.85;
}
.recbar .wave {
  color: var(--red);
}
.wave.live i {
  animation: wavebar 0.9s var(--ease-io) infinite alternate;
}
.wave.live i:nth-child(3n) {
  animation-delay: -0.3s;
}
.wave.live i:nth-child(3n + 1) {
  animation-delay: -0.6s;
}
@keyframes wavebar {
  to {
    transform: scaleY(0.35);
  }
}
.b.voice {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 230px;
  padding: 8px 12px;
}
.vplay {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgb(255 255 255 / 0.25);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.vplay svg {
  margin-left: 2px;
}
.b.voice .dur {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.vtext {
  align-self: flex-end;
  max-width: 250px;
  font-size: 13px;
  line-height: 18px;
  color: var(--p-muted);
  text-align: right;
  padding: 0 6px;
}
.lpanel {
  width: 360px;
  flex-shrink: 0;
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  height: 560px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgb(0 0 0 / 0.08);
  font-size: 14px;
}
.lhead {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}
.lhead b {
  display: block;
  font-size: 15px;
}
.lhead small {
  color: var(--subtle);
  font-size: 12px;
}
.lav {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #c2410c;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: 12px;
}
.lthread {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  padding: 14px 16px;
  overflow: hidden;
}
.lthread > * {
  flex-shrink: 0;
}
.lm {
  max-width: 290px;
  padding: 9px 12px;
  border-radius: 14px;
  line-height: 1.45;
  background: var(--panel);
  border: 1px solid var(--line);
  align-self: flex-start;
}
.lm.ai {
  background: color-mix(in srgb, var(--purple) 8%, var(--card));
  border-color: color-mix(in srgb, var(--purple) 22%, var(--line));
  align-self: flex-end;
}
.lm.me {
  background: color-mix(in srgb, var(--blue) 10%, var(--card));
  border-color: color-mix(in srgb, var(--blue) 26%, var(--line));
  align-self: flex-end;
}
.lm .tag {
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.02em;
  color: var(--subtle);
  margin-bottom: 4px;
}
.lm .tag svg {
  width: 11px;
  height: 11px;
}
.lsys {
  align-self: center;
  font-size: 12px;
  color: #b45309;
  background: color-mix(in srgb, #f59e0b 14%, var(--card));
  border-radius: 999px;
  padding: 4px 12px;
}
.lcompose {
  margin: 0 12px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  color: var(--subtle);
  display: flex;
  justify-content: space-between;
  gap: 8px;
  min-height: 42px;
}
.lcompose span.on {
  color: var(--fg);
}
.lcompose i {
  font-style: normal;
  font-family: var(--mono);
  font-size: 12px;
}
@media (max-width: 820px) {
  .lang {
    flex-direction: column;
  }
  .lpanel {
    width: min(360px, 100%);
    height: 470px;
  }
}

/* ---------- Actions in the chat -------------------------------------------- */

.aover {
  position: absolute;
  z-index: 6;
  transition:
    transform 0.5s var(--ease),
    opacity 0.3s;
}
.asheet {
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--p-card);
  border-radius: 28px 28px 0 0;
  padding: 8px 18px 34px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transform: translateY(105%);
}
.asheet.in,
.ascreen.in {
  transform: none;
}
.ah {
  text-align: center;
  font-size: 17px;
  padding: 6px 0 4px;
}
.arow {
  display: flex;
  gap: 12px;
  align-items: center;
  background: var(--p-bg);
  border-radius: 14px;
  padding: 12px;
}
.arow b {
  display: block;
  font-size: 15px;
}
.arow small,
.afine {
  font-size: 12px;
  color: var(--p-muted);
}
.afine {
  text-align: center;
}
.aic {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(160deg, #ffb066, #f2541b);
  color: #fff;
  font-weight: 800;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.aic.big {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  font-size: 24px;
}
.apick {
  display: flex;
  justify-content: space-between;
  background: var(--p-bg);
  border-radius: 14px;
  padding: 13px 14px;
  font-size: 14px;
}
.apick b {
  color: var(--blue);
  font-weight: 500;
}
.abtn {
  background: var(--blue);
  color: #fff;
  text-align: center;
  border-radius: 14px;
  padding: 14px;
  font-weight: 600;
}
.aalert {
  left: 55px;
  right: 55px;
  top: 250px;
  border-radius: 18px;
  background: color-mix(in srgb, var(--p-card) 96%, transparent);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  padding: 20px 16px 0;
  opacity: 0;
  transform: scale(1.1);
}
.aalert.in {
  opacity: 1;
  transform: none;
}
.aalert b {
  font-size: 17px;
  margin-top: 6px;
}
.aalert small {
  font-size: 13px;
  color: var(--p-muted);
  line-height: 1.35;
}
.stars {
  display: flex;
  gap: 6px;
  font-size: 30px;
  color: color-mix(in srgb, var(--p-muted) 45%, transparent);
  padding: 8px 0 12px;
}
.stars i {
  font-style: normal;
  transition: color 0.15s;
}
.stars i.on {
  color: var(--blue);
}
.anot {
  align-self: stretch;
  border-top: 1px solid var(--p-line);
  color: var(--blue);
  padding: 12px;
  font-size: 16px;
}
.ascreen {
  inset: 0;
  background: var(--p-bg);
  transform: translateX(102%);
  display: flex;
  flex-direction: column;
}
.anav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  padding: 4px 16px 12px;
  font-size: 17px;
}
.anav span:first-child {
  color: var(--blue);
}
.ascreen .app {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 12px 18px;
}
.atime {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--p-card);
  border-radius: 16px;
  padding: 16px;
  font-size: 16px;
  border: 2px solid transparent;
  transition:
    border-color 0.4s,
    background 0.4s;
}
.atime b {
  font-size: 22px;
  font-variant-numeric: tabular-nums;
}
.atime.hl {
  border-color: var(--blue);
  background: color-mix(in srgb, var(--blue) 8%, var(--p-bg));
}
.aart {
  padding: 8px 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.aart small {
  color: var(--p-muted);
  font-size: 13px;
}
.aart h4 {
  margin: 0;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.12;
}
.aart p {
  margin: 0;
  font-size: 17px;
  line-height: 1.5;
}
.ahelp {
  margin-top: 10px;
  display: flex;
  gap: 12px;
  align-items: center;
  color: var(--p-muted);
  font-size: 14px;
}
.ahelp span {
  background: var(--p-card);
  border-radius: 999px;
  padding: 4px 12px;
}

/* ---------- Scheduled feedback calls --------------------------------------- */

.mface {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  object-fit: cover;
}
.cal {
  align-self: stretch;
  border: 1px solid var(--p-line);
  border-radius: 18px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--p-bg);
}
.chead {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.chead b {
  font-size: 16px;
}
.chead small {
  font-size: 12px;
  color: var(--p-muted);
}
.days {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.days span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 8px 0;
  border-radius: 12px;
  background: var(--p-card);
  font-weight: 600;
  font-size: 17px;
  transition:
    background 0.2s,
    color 0.2s;
}
.days small {
  font-size: 11px;
  font-weight: 500;
  color: var(--p-muted);
}
.days .na {
  opacity: 0.35;
}
.days span.sel,
.slots span.sel {
  background: var(--blue);
  color: #fff;
}
.days span.sel small {
  color: rgb(255 255 255 / 0.8);
}
.slots {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition:
    max-height 0.4s var(--ease),
    opacity 0.3s;
}
.slots.in {
  max-height: 60px;
  opacity: 1;
}
.slots span {
  text-align: center;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 0;
  border-radius: 10px;
  border: 1px solid var(--p-line);
  color: var(--blue);
}
.cbtn {
  background: var(--blue);
  color: #fff;
  text-align: center;
  border-radius: 12px;
  font-weight: 600;
  font-size: 15px;
  max-height: 0;
  padding: 0;
  opacity: 0;
  overflow: hidden;
  transition:
    max-height 0.4s var(--ease),
    padding 0.4s var(--ease),
    opacity 0.3s;
}
.cbtn.in {
  max-height: 60px;
  padding: 11px;
  opacity: 1;
}
.calrow {
  align-self: flex-start;
  display: flex;
  gap: 10px;
  align-items: center;
  border: 1px solid var(--p-line);
  border-radius: 14px;
  padding: 8px 12px 8px 8px;
}
.calrow b {
  display: block;
  font-size: 14px;
}
.calrow small {
  font-size: 12px;
  color: var(--p-muted);
}
.cd {
  width: 40px;
  border-radius: 9px;
  overflow: hidden;
  background: var(--p-card);
  text-align: center;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.3;
}
.cd small {
  display: block;
  background: var(--red);
  color: #fff;
  font-size: 9px;
  letter-spacing: 0.06em;
}

/* Tapping a step fast-forwards its demo: no transitions while it does */
.ff,
.ff * {
  transition: none !important;
}

/* On phones the dashboard drops its side columns so the chat stays readable */
@media (max-width: 640px) {
  .dash {
    aspect-ratio: 600 / 720;
  }
  .dcanvas {
    width: 600px;
    height: 720px;
    font-size: 14px;
  }
  .dcanvas .drail,
  .dcanvas .dlist,
  .dcanvas .dside {
    display: none;
  }
  .dchrome span {
    padding: 3px 24px;
  }
}
