/* =========================================================
   Tokens
   ========================================================= */
:root {
  --canvas: #F4F5F7;
  --dot: #D5D9DE;
  --paper: #FFFFFF;
  --paper-2: #F5F6F7;
  --ink: #17181B;
  --ink-2: #53575F;
  --ink-3: #8A8F97;
  --line: #E2E4E7;
  --line-2: #CFD3D8;
  --chrome: #FFFFFF;
  --chrome-line: #E3E5E8;
  --shadow: 0 1px 2px rgb(20 22 26 / 6%), 0 8px 28px rgb(20 22 26 / 8%);
  --shadow-lg: 0 2px 4px rgb(20 22 26 / 6%), 0 24px 60px rgb(20 22 26 / 14%);

  --sel: #1E80FF;
  --r: #FF6A2B;       /* Rushabh */
  --a: #7456F5;       /* Ananya */
  --a-soft: #EEEAFE;
  --you: #13A65A;
  --dobby: #0B8F7E;

  --c-yellow: #FFE27A;
  --c-pink: #FFB8CB;
  --c-green: #AEE8BD;
  --c-blue: #A3D5FF;
  --c-violet: #D3C6FF;
  --c-orange: #FFC7A0;
  --sticky-ink: #1D1B16;
  --hl: rgb(255 214 90 / 70%);

  --display: "Gloock", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --ui: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --hand: "Shantell Sans", "Comic Neue", "Segoe Print", "Bradley Hand", cursive;

  --ease: cubic-bezier(.2, .75, .15, 1);
  --topbar: 56px;

  color-scheme: light;
}

/* Light is the default for everyone; dark only when the visitor picks it. */
:root[data-theme="dark"] {
  --canvas: #141518;
  --dot: #2C2F35;
  --paper: #1D1F23;
  --paper-2: #24272C;
  --ink: #ECEDEF;
  --ink-2: #A8ADB5;
  --ink-3: #737881;
  --line: #2C2F35;
  --line-2: #3A3E45;
  --chrome: #1B1D21;
  --chrome-line: #2C2F35;
  --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 28px rgb(0 0 0 / 35%);
  --shadow-lg: 0 2px 4px rgb(0 0 0 / 30%), 0 24px 60px rgb(0 0 0 / 50%);
  --a: #957DFF;
  --a-soft: #2A2448;
  --dobby: #2BC4AE;
  --c-yellow: #F1D46E;
  --c-pink: #F0A9BD;
  --c-green: #9DD9AD;
  --c-blue: #93C6F0;
  --c-violet: #C2B4F2;
  --c-orange: #F0B78F;
  --hl: rgb(255 106 43 / 34%);
  color-scheme: dark;
}

/* =========================================================
   Base
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--canvas);
  background-image: radial-gradient(var(--dot) 1.1px, transparent 1.2px);
  background-size: 24px 24px;
  color: var(--ink);
  font-family: var(--ui);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  font-synthesis-weight: none; /* Gloock has one weight; never fake-bold it */
}
h1, h2, h3, h4, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }
code, kbd { font-family: var(--mono); }
:focus-visible { outline: 2px solid var(--sel); outline-offset: 2px; }
[hidden] { display: none !important; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.hl { background: linear-gradient(transparent 55%, var(--hl) 55%); color: var(--ink); font-weight: 600; padding: 0 2px; border-radius: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.c-yellow { --c: var(--c-yellow); }
.c-pink { --c: var(--c-pink); }
.c-green { --c: var(--c-green); }
.c-blue { --c: var(--c-blue); }
.c-violet { --c: var(--c-violet); }
.c-orange { --c: var(--c-orange); }

/* =========================================================
   Chrome: top bar
   ========================================================= */
.topbar {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  height: var(--topbar); padding-inline: 12px;
  background: var(--chrome); border-bottom: 1px solid var(--chrome-line);
}
.tb-left, .tb-right { display: flex; align-items: center; gap: 10px; min-width: 0; }
.logo {
  display: grid; place-items: center; width: 32px; height: 32px; border: 0; border-radius: 8px;
  background: var(--ink); color: var(--paper);
  font-family: var(--display); font-weight: 800; font-size: 13px; letter-spacing: -.02em;
}
.crumbs { display: flex; gap: 6px; font-size: 13px; white-space: nowrap; overflow: hidden; }
.crumb-dim { color: var(--ink-3); }
.crumb-slash { color: var(--line-2); }
.crumb-file { font-weight: 600; }

.presence { display: flex; margin-right: 4px; }
.av {
  display: grid; place-items: center; height: 28px; min-width: 28px; padding-inline: 6px;
  border-radius: 999px; border: 2px solid var(--chrome);
  color: #fff; font-size: 11px; font-weight: 700;
}
.av + .av { margin-left: -6px; }
.av-r { background: var(--r); }
.av-d { background: var(--dobby); padding: 0; overflow: hidden; }
.av-d svg { width: 24px; height: 24px; }
.av-you { background: var(--you); }

.tb-btn {
  height: 32px; padding-inline: 12px; border-radius: 8px; border: 1px solid transparent;
  font-size: 13px; font-weight: 600; white-space: nowrap;
}
.tb-tour { background: var(--dobby); color: #fff; }
.tb-tour:hover { filter: brightness(1.08); }
.tb-ghost { background: transparent; border-color: var(--chrome-line); }
.tb-ghost:hover { background: var(--paper-2); }
.tb-icon {
  display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px;
  background: transparent; border: 1px solid var(--chrome-line);
}
.tb-icon svg { width: 16px; height: 16px; fill: none; stroke: var(--ink); stroke-width: 1.6; }
.tb-icon svg path { fill: var(--ink); stroke: none; }

/* =========================================================
   Page layout (default, no-JS and "Read as a page")
   ========================================================= */
.panel, .zoombox, .minimap, .cursors, .board-only, .connectors { display: none; }

.viewport { position: relative; }
.world {
  display: flex; flex-direction: column; gap: 56px;
  max-width: 1120px; margin-inline: auto;
  padding: 40px 16px 140px;
}
#hello { order: 1; } #whatsapp { order: 2; } #crew { order: 3; } #metrics { order: 4; } #ola { order: 5; }
#chakr { order: 6; } #roadmap { order: 7; } #principles { order: 8; } #contact { order: 9; }

.frame { position: relative; container-type: inline-size; }
.frame-label {
  font-family: var(--ui); font-size: 12px; font-weight: 600; color: var(--ink-2);
  margin: 0 0 8px 2px; white-space: nowrap;
}
.paper {
  position: relative;
  background: var(--paper); border-radius: 8px; border: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: clamp(20px, 4.5cqi, 44px);
}
.frame.is-focus .paper { box-shadow: 0 0 0 2px var(--sel), var(--shadow); }

/* shared type */
.ui-tag {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 11.5px; color: var(--ink-2); letter-spacing: .01em;
}
.f-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px; margin-bottom: 24px; }
.f-title {
  font-family: var(--display); font-weight: 700; font-size: clamp(1.5rem, 4cqi, 2.1rem);
  font-variation-settings: "opsz" 48; line-height: 1.08; letter-spacing: -.025em;
  margin-block: 8px 12px;
}
.f-head .f-title { margin: 0; }
.f-hint { font-family: var(--hand); font-size: 15px; color: var(--ink-3); }
.f-body { color: var(--ink-2); max-width: 62ch; }

.pulse { position: relative; width: 7px; height: 7px; border-radius: 50%; background: var(--you); flex: none; }
.pulse::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--you); animation: ping 2.2s var(--ease) infinite; }
@keyframes ping { 0% { transform: scale(1); opacity: .55; } 80%, 100% { transform: scale(3.2); opacity: 0; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 10px 16px; border-radius: 10px;
  border: 1px solid var(--line-2); background: var(--paper);
  font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: transform .2s var(--ease), background-color .2s, border-color .2s;
}
.btn:hover { transform: translateY(-1px); border-color: var(--ink-3); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.btn-primary:hover { background: var(--a); border-color: var(--a); color: #fff; }
.link-btn {
  background: none; border: 0; padding: 0; color: var(--a); font-weight: 600; font-size: 14px;
  text-decoration: underline; text-underline-offset: 3px;
}

.hand { font-family: var(--hand); font-variation-settings: "INFM" 60; color: var(--ink-2); font-size: 18px; line-height: 1.3; }
.hand-arrow { fill: none; stroke: var(--ink-3); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Hello ---------- */
.paper-hello { padding: clamp(24px, 6cqi, 56px); }
.sticker {
  position: absolute; top: -14px; right: 28px; transform: rotate(4deg);
  background: var(--c-yellow); color: var(--sticky-ink);
  font-family: var(--hand); font-weight: 600; font-size: 14px;
  padding: 6px 12px; box-shadow: 0 6px 14px rgb(0 0 0 / 12%);
}
.hello-name {
  font-family: var(--display); font-weight: 800;
  font-variation-settings: "opsz" 96, "wdth" 85;
  font-size: clamp(3.2rem, 13cqi, 6rem); line-height: .92; letter-spacing: -.02em;
  margin-block: 20px 18px;
}
.hello-name .dot { color: var(--r); }
.hello-line { font-family: var(--ui); font-weight: 500; font-size: clamp(1.2rem, 3.2cqi, 1.6rem); line-height: 1.3; letter-spacing: -.012em; color: var(--ink); max-width: 30ch; }
.hello-line .own { font-weight: 700; text-transform: uppercase; letter-spacing: .03em; color: var(--r); }
.hello-body { color: var(--ink-2); margin-top: 12px; max-width: 58ch; }
.hello-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.hello-foot { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 18px 24px; margin-top: 26px; }
.now {
  max-width: 260px; padding: 12px 14px 13px; display: grid; gap: 4px;
  background: var(--c); color: var(--sticky-ink); transform: rotate(-1.5deg);
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 8px 16px -6px rgb(0 0 0 / 22%);
  font-family: var(--hand); font-variation-settings: "INFM" 40; font-size: 14.5px; line-height: 1.3;
}
.now-k { font-family: var(--mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; opacity: .7; }

/* receipts: proof on the first screen */
.receipts-k { display: flex; align-items: baseline; gap: 10px; margin-top: 28px; font-family: var(--hand); font-variation-settings: "INFM" 60; font-size: 15px; color: var(--ink-3); }
.receipts-k span { font-weight: 700; color: var(--r); font-size: 17px; }
.receipts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 12px; }
.receipt {
  width: 100%; height: 100%; display: grid; gap: 6px; align-content: start; text-align: left;
  padding: 14px 14px 12px; border: 0; background: var(--c); color: var(--sticky-ink);
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 8px 18px -6px rgb(0 0 0 / 22%);
  transform: rotate(var(--rot, -1.5deg));
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.receipts li:nth-child(2) .receipt { --rot: 1.2deg; }
.receipts li:nth-child(3) .receipt { --rot: -.6deg; }
.receipts li:nth-child(4) .receipt { --rot: 1.8deg; }
.receipt:hover, .receipt:focus-visible { transform: translateY(-5px) rotate(0deg); box-shadow: 0 2px 2px rgb(0 0 0 / 6%), 0 20px 30px -10px rgb(0 0 0 / 30%); }
.rc-num { font-family: var(--display); font-weight: 800; font-size: clamp(1.8rem, 4.4cqi, 2.4rem); line-height: 1; letter-spacing: -.04em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rc-num .u, .gr-to .u { font-family: var(--ui); font-weight: 600; font-size: .78em; margin-left: .04em; }
.rc-k { font-size: 14px; line-height: 1.35; }
.rc-go { font-family: var(--mono); font-size: 11.5px; opacity: .7; margin-top: 4px; }
.receipt:hover .rc-go { opacity: 1; text-decoration: underline; text-underline-offset: 2px; }

.tb-hi { background: transparent; border-color: var(--chrome-line); }
.tb-hi:hover { background: var(--paper-2); }

/* SOLD stamp */
.stamp {
  position: absolute; right: 52px; top: 112px; z-index: 2;
  display: grid; justify-items: center; gap: 2px; padding: 8px 16px 9px;
  border: 3px solid var(--r); border-radius: 10px; color: var(--r);
  transform: rotate(-11deg); line-height: 1; pointer-events: none;
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--r) 25%, transparent);
}
.stamp b { font-family: var(--display); font-weight: 800; font-size: 2.3rem; letter-spacing: .08em; text-transform: uppercase; font-variation-settings: "wdth" 80; }
.stamp { font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.stamp.is-slam { animation: slam .5s cubic-bezier(.3, 1.6, .5, 1) both; }
@keyframes slam { 0% { opacity: 0; transform: rotate(-24deg) scale(2.4); } 60% { opacity: 1; } 100% { opacity: 1; transform: rotate(-11deg) scale(1); } }
.receipts-k, .receipts { position: relative; z-index: 3; }

/* ---------- Tara flow ---------- */
.flow {
  position: relative; margin-top: 26px;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 44px 30px;
}
.flow-lines { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 0; }
.flow-lines .fl { fill: none; stroke: var(--line-2); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 2 9; }
.flow-home { z-index: 3; }
.flow-home .home circle { fill: var(--paper); stroke: var(--r); stroke-width: 2.5; filter: drop-shadow(0 3px 6px rgb(0 0 0 / 22%)); }
.flow-home .home path { fill: var(--r); }
.flow-home .home rect { fill: var(--paper); }
.node {
  position: relative; z-index: 1;
  grid-column: var(--c-i); grid-row: var(--r-i);
  display: grid; gap: 3px; align-content: start; text-align: left;
  padding: 12px 14px 14px; min-height: 104px;
  border: 0; border-radius: 12px; background: var(--c); color: var(--sticky-ink);
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 8px 18px -8px rgb(0 0 0 / 25%);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.node b { font-family: var(--display); font-weight: 800; font-size: 1.12rem; letter-spacing: -.015em; line-height: 1.1; }
.node > span:last-child { font-size: 12.5px; line-height: 1.3; }
.n-tag { font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; opacity: .6; }
.node:hover { transform: translateY(-3px); }
.node.is-on { box-shadow: 0 0 0 2px var(--paper), 0 0 0 4px var(--sel), 0 10px 20px -8px rgb(0 0 0 / 25%); }
.node.is-ping { animation: ping-node .6s var(--ease); }
@keyframes ping-node { 40% { transform: translateY(-4px) scale(1.04); } }
.node-wip { background: var(--paper); color: var(--ink-2); border: 2px dashed var(--line-2); box-shadow: none; }
.node-sold { background: var(--paper); color: var(--r); border: 3px solid var(--r); }
.node-sold b { font-size: 1.5rem; letter-spacing: .08em; font-variation-settings: "wdth" 80; }
.node-sold > span:last-child { color: var(--ink-2); }
.flow-detail {
  margin-top: 22px; padding: 14px 16px; border-radius: 10px;
  background: var(--paper-2); border: 1px solid var(--line); display: grid; gap: 4px; min-height: 92px;
}
.fd-title { font-family: var(--display); font-weight: 800; font-size: 1.15rem; letter-spacing: -.015em; }
.flow-detail p:last-child { color: var(--ink-2); max-width: 80ch; }

/* ---------- Photo polaroid ---------- */
.polaroid {
  position: absolute; left: min(560px, calc(100% - 240px)); top: 54px; z-index: 1; margin: 0;
  width: 172px; padding: 10px 10px 30px; background: #fff; color: #1d1b16;
  transform: rotate(4deg); box-shadow: 0 2px 3px rgb(0 0 0 / 8%), 0 18px 30px -12px rgb(0 0 0 / 30%);
}
.polaroid img { display: block; width: 100%; height: auto; aspect-ratio: 9 / 10; object-fit: cover; object-position: 50% 8%; background: linear-gradient(160deg, #DCEBFA 0%, #C9DDF2 100%); }
.polaroid figcaption { position: absolute; left: 0; right: 0; bottom: 6px; text-align: center; font-family: var(--hand); font-size: 14px; }
.polaroid::before { content: ""; position: absolute; top: -10px; left: 50%; width: 70px; height: 20px; margin-left: -35px; background: rgb(255 230 150 / 75%); transform: rotate(-3deg); }
.polaroid .stamp-photo {
  top: auto; right: auto; left: -46px; bottom: 26px; padding: 5px 12px 6px;
  background: color-mix(in srgb, #fff 90%, transparent); transform: rotate(-10deg);
}
.polaroid .stamp-photo small { font-family: var(--mono); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }
.polaroid .stamp-photo b { font-size: 1.4rem; letter-spacing: .04em; white-space: nowrap; }
.polaroid .stamp-photo.is-slam { animation: slam-photo .5s cubic-bezier(.3, 1.6, .5, 1) both; }
@keyframes slam-photo { 0% { opacity: 0; transform: rotate(-22deg) scale(2.2); } 60% { opacity: 1; } 100% { opacity: 1; transform: rotate(-10deg) scale(1); } }
.paper-hello.has-photo .sticker { right: auto; left: 40%; }
/* wide hello: a bigger photo centred in the space right of the name */
@container (min-width: 960px) {
  .polaroid { width: 220px; left: calc(50% + 100px); top: 92px; padding: 12px 12px 36px; }
  .polaroid figcaption { font-size: 16px; bottom: 8px; }
}

/* ---------- WhatsApp duo ---------- */
.btn-play { gap: 10px; }
.duo { display: grid; grid-template-columns: 340px minmax(0, 1fr) 340px; gap: 28px; margin-top: 26px; align-items: stretch; }
.duo .phone { height: 600px; transition: box-shadow .3s var(--ease), transform .3s var(--ease); }
.duo .phone.is-active { box-shadow: inset 0 0 0 6px var(--paper), 0 0 0 3px var(--sel), var(--shadow-lg); transform: translateY(-4px); }
.phone-av { width: 34px; height: 34px; flex: none; }
.phone-cta {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
  padding: 11px 14px; border-radius: 999px; background: #25D366; color: #0B2E1A;
  font-size: 13.5px; font-weight: 700; text-decoration: none;
  transition: transform .2s var(--ease), filter .2s;
}
.phone-cta:hover { transform: translateY(-1px); filter: brightness(1.05); }
.phone-cta svg { width: 16px; height: 16px; fill: currentColor; }
#phone-tara > .phone-cta { width: auto; margin: 12px 14px 16px; }
.phone-chips { gap: 8px; }
.phone-foot { padding: 12px 14px 16px; border-top: 1px solid var(--line); background: var(--paper); font-family: var(--mono); font-size: 11px; color: var(--ink-3); text-align: center; }
.phone-chips .chip { width: 100%; }
.duo-mid { position: relative; display: flex; flex-direction: column; gap: 18px; justify-content: center; padding: 8px 4px; }
.dn { display: grid; gap: 10px; padding: 18px 18px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.dn-k { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 14px; }
.av-sm { width: 30px; height: 30px; flex: none; }
.dn ul { display: grid; gap: 8px; }
.dn li { font-size: 14px; color: var(--ink-2); line-height: 1.4; }
.dn b { color: var(--ink); }
.story-state { font-family: var(--mono); font-size: 11px; color: var(--ink-3); text-align: center; }
.story-state.is-live { color: var(--dobby); }
.stamp-story { position: absolute; left: 50%; top: 50%; right: auto; margin: -40px 0 0 -90px; z-index: 5; background: color-mix(in srgb, var(--paper) 88%, transparent); }
.flow-k { margin-top: 36px; font-family: var(--ui); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }
.flow-k span { font-family: var(--hand); text-transform: none; letter-spacing: 0; font-weight: 400; font-size: 14px; }
.flow { margin-top: 6px; }
.n-av { position: absolute; right: 10px; top: 10px; width: 30px; height: 30px; }
.minis-half { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 640px; }
.minis-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.minis-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* ---------- Ananya leaks ---------- */
.leaks { display: grid; gap: 8px; counter-reset: leak; color: var(--ink-2); }
.leaks li { position: relative; padding-left: 34px; counter-increment: leak; }
.leaks li::before {
  content: counter(leak); position: absolute; left: 0; top: 1px;
  display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  background: var(--a-soft); color: var(--a); font-family: var(--mono); font-size: 11px; font-weight: 600;
}
.leaks b { color: var(--ink); }

/* ---------- Crew badges ---------- */
.crew { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-top: 24px; }
.badge { border: 0; padding: 0; background: none; perspective: 1000px; height: 250px; text-align: left; color: var(--sticky-ink); }
.badge-in { position: relative; display: block; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform .75s var(--ease); }
.badge:hover .badge-in { transform: rotateY(-8deg) translateY(-3px); }
.badge[aria-pressed="true"] .badge-in { transform: rotateY(180deg); }
.badge-f, .badge-b {
  position: absolute; inset: 0; display: flex; flex-direction: column; gap: 10px;
  padding: 30px 18px 18px; border-radius: 12px; background: var(--c);
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 12px 24px -10px rgb(0 0 0 / 28%);
  font-size: 13.5px; line-height: 1.4;
}
.badge-f::before, .badge-b::before {
  content: ""; position: absolute; top: 11px; left: 50%; width: 38px; height: 7px; margin-left: -19px;
  border-radius: 4px; background: rgb(0 0 0 / 16%);
}
.badge-b { transform: rotateY(180deg); background: color-mix(in srgb, var(--c) 70%, var(--paper)); }
.b-av { width: 64px; height: 64px; flex: none; filter: drop-shadow(0 3px 6px rgb(0 0 0 / 15%)); }
.b-name { font-family: var(--display); font-weight: 800; font-size: 1.35rem; letter-spacing: -.02em; line-height: 1.05; }
.b-role { font-family: var(--hand); font-variation-settings: "INFM" 50; font-size: 17px; line-height: 1.3; }
.b-tag, .b-stat { margin-top: auto; font-family: var(--mono); font-size: 10.5px; opacity: .65; }
.badge-b strong { font-family: var(--display); font-weight: 800; font-size: 1.1rem; }
.also { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-top: 22px; padding: 14px 16px; border: 1.5px dashed var(--line-2); border-radius: 12px; }
.also-k { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); }
.also-t { font-size: 14.5px; color: var(--ink-2); }
.also-t b { color: var(--ink); }
.stack { margin-top: 16px; font-size: 14px; color: var(--ink-2); }
.stack > span:first-child { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); margin-right: 8px; }
.hand-inline { font-family: var(--hand); color: var(--r); font-size: 16px; margin-left: 6px; }

/* ---------- Roadmap ---------- */
.rm { display: grid; gap: 12px; padding-top: 26px; position: relative; }
.rm-axis { position: absolute; top: 0; left: 150px; right: 0; height: 100%; pointer-events: none; }
.rm-axis span {
  position: absolute; left: var(--at); top: 0; bottom: 0; border-left: 1px dashed var(--line-2);
  font-family: var(--mono); font-size: 11px; color: var(--ink-3); padding-left: 6px;
}
.rm-lane { display: grid; grid-template-columns: 150px minmax(0, 1fr); align-items: center; }
.rm-lane-k { font-size: 13px; color: var(--ink-2); font-weight: 500; padding-right: 12px; }
.rm-track { position: relative; height: 44px; }
.rm-bar {
  position: absolute; top: 4px; bottom: 4px; left: var(--s); width: calc(var(--e) - var(--s));
  background: var(--c); color: var(--sticky-ink); border: 0; border-radius: 8px;
  font-size: 13px; font-weight: 600; text-align: left; padding: 0 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.rm-bar:hover { transform: translateY(-2px); box-shadow: 0 6px 14px rgb(0 0 0 / 12%); }
/* each bar wears its organisation's own logo colours */
.rm-bar[data-rm="iitg"] { background: #1E4495; color: #fff; border-left: 6px solid #D2B428; }
.rm-bar[data-rm="ola"] { background: #000; color: #D6DF22; }
.rm-bar[data-rm="chakr"] { background: #F8A323; color: #1d1b16; border-left: 6px solid #22B574; }
.rm-bar[data-rm="jumbo"] { background: #740101; color: #fff; }
.rm-bar.is-on { box-shadow: 0 0 0 2px var(--paper), 0 0 0 4px var(--sel); }
.rm-details { margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }
.rm-detail { display: grid; gap: 6px; max-width: 70ch; }
.rm-d-title { font-family: var(--display); font-weight: 700; font-size: 1.3rem; letter-spacing: -.015em; }
.rm-detail > p:not(.ui-tag):not(.rm-d-title) { color: var(--ink-2); }
.rm-detail .link-btn { justify-self: start; margin-top: 4px; }

/* ---------- OLA scatter ---------- */
.scatter { position: relative; margin: 22px 0 0; }
.callouts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 16px; }
.callout {
  display: grid; gap: 2px; justify-items: start; text-align: left;
  padding: 12px 14px; border-radius: 10px; background: var(--c); color: var(--sticky-ink);
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 8px 16px -6px rgb(0 0 0 / 22%); font-size: 12px;
}
.callout b { font-family: var(--ui); font-weight: 700; font-size: 1.35rem; letter-spacing: -.02em; line-height: 1.1; }
.scatter svg { width: 100%; max-width: 640px; margin-inline: auto; height: auto; display: block; overflow: visible; }
.scatter figcaption { font-family: var(--mono); font-size: 11px; color: var(--ink-3); margin-top: 8px; }
.scatter-tip {
  position: absolute; pointer-events: none; transform: translate(-50%, -130%);
  background: var(--ink); color: var(--paper); font-family: var(--mono); font-size: 11px;
  padding: 5px 8px; border-radius: 6px; white-space: nowrap;
}
.sc-grid { stroke: var(--line); stroke-width: 1; }
.sc-axis { stroke: var(--ink-3); stroke-width: 1; fill: none; }
.sc-label { fill: var(--ink-3); font-family: var(--mono); font-size: 10px; }
.sc-diag { stroke: var(--r); stroke-width: 1.5; stroke-dasharray: 5 5; fill: none; }
.sc-dot { fill: var(--ink); cursor: crosshair; transition: r .15s, fill .15s; }
.sc-dot:hover, .sc-dot.is-hot { fill: var(--r); r: 6; }
.sc-r2 { fill: var(--r); font-family: var(--display); font-weight: 800; font-size: 30px; }
.sc-r2k { fill: var(--ink-3); font-family: var(--mono); font-size: 10px; }

.minis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 24px; }
.minis-wide { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 28px; }
.mini {
  background: var(--c); color: var(--sticky-ink);
  padding: 14px 14px 16px; font-size: 13px; line-height: 1.35;
  box-shadow: 0 4px 10px rgb(0 0 0 / 8%);
  display: grid; gap: 6px; align-content: center; justify-items: center; text-align: center;
  border-radius: 10px;
}
.mini b { font-family: var(--ui); font-weight: 700; font-size: 1.3rem; letter-spacing: -.02em; line-height: 1.1; }

/* ---------- Chakr notebook ---------- */
.paper-grid {
  background-color: var(--paper);
  background-image:
    linear-gradient(color-mix(in srgb, var(--c-blue) 38%, transparent) 1px, transparent 1px),
    linear-gradient(90deg, color-mix(in srgb, var(--c-blue) 38%, transparent) 1px, transparent 1px);
  background-size: 20px 20px;
}
.cell {
  margin-top: 22px; border: 1.5px solid var(--ink); border-radius: 4px; background: var(--paper);
  display: grid;
}
.cell-canvas { width: 100%; height: auto; display: block; aspect-ratio: 640 / 240; border-bottom: 1.5px solid var(--ink); }
.cell-ctrl { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; align-items: center; padding: 14px 16px 16px; }
.cell-k { font-size: 13px; color: var(--ink-2); font-weight: 500; }
.cell-v { font-family: var(--display); font-weight: 800; font-size: 1.6rem; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.cell-ctrl input { grid-column: 1 / -1; width: 100%; accent-color: var(--r); }
.cell-scale { grid-column: 1 / -1; display: flex; justify-content: space-between; gap: 8px; font-family: var(--mono); font-size: 10.5px; color: var(--ink-3); }
.cell-cap { font-family: var(--mono); font-size: 11px; color: var(--ink-3); margin: 10px auto 0; max-width: 70ch; text-align: center; }

.notes-hand {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 28px; margin-top: 22px;
  font-family: var(--hand); font-variation-settings: "INFM" 70; font-size: 16.5px; line-height: 1.35; color: var(--ink);
}
.notes-hand li { position: relative; padding-left: 18px; }
.notes-hand li::before { content: "→"; position: absolute; left: 0; color: var(--r); }
.notes-hand .hl { font-weight: 700; background: linear-gradient(transparent 55%, color-mix(in srgb, var(--c-yellow) 85%, transparent) 55%); padding-inline: 2px; }
.notes-hand u { text-decoration-color: var(--r); text-decoration-thickness: 2px; text-underline-offset: 3px; }

/* ---------- Ananya PRD ---------- */
.prd { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(24px, 4cqi, 48px); align-items: start; }
.doc-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 13px; color: var(--ink-3); }
.pill { background: color-mix(in srgb, var(--you) 16%, transparent); color: var(--you); font-weight: 700; font-size: 11.5px; padding: 3px 9px; border-radius: 999px; }
.doc-title {
  font-family: var(--display); font-weight: 800; font-size: clamp(1.7rem, 3.6cqi, 2.4rem);
  font-variation-settings: "opsz" 60; line-height: 1.05; letter-spacing: -.03em; margin-block: 12px 8px;
}
.prd-doc h4 {
  font-family: var(--ui); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink-3); margin: 22px 0 6px;
}
.prd-doc > p { color: var(--ink-2); max-width: 60ch; }
.tool-list { display: grid; gap: 6px; color: var(--ink-2); }
.tool-list code { font-size: 12.5px; background: var(--a-soft); color: var(--a); padding: 1px 6px; border-radius: 4px; }
.result { display: grid; gap: 2px; }
.result-num { display: flex; align-items: baseline; gap: 12px; font-family: var(--display); font-weight: 800; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.r-from { font-size: 1.7rem; color: var(--ink-3); font-weight: 600; }
.r-arrow { font-size: 1.4rem; color: var(--ink-3); }
.r-to { font-size: clamp(3rem, 8cqi, 4.4rem); line-height: 1; color: var(--a); }
.result-k { font-size: 13px; color: var(--ink-3); }

.phone {
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto;
  height: 620px;
  border-radius: 26px; border: 1px solid var(--line-2);
  background: var(--paper-2); overflow: hidden;
  box-shadow: inset 0 0 0 6px var(--paper), var(--shadow);
}
.phone-top {
  display: flex; align-items: center; gap: 10px; padding: 16px 18px 12px;
  border-bottom: 1px solid var(--line); background: var(--paper);
}
.phone-av { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--a); color: #fff; font-weight: 700; font-size: 14px; }
.phone-name { display: grid; font-weight: 600; font-size: 14px; line-height: 1.2; margin-right: auto; }
.phone-name small { font-weight: 400; font-size: 11.5px; color: var(--ink-3); }
.phone-status { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; color: var(--you); }
.phone-msgs {
  display: flex; flex-direction: column; gap: 8px; padding: 16px 14px;
  overflow-y: auto; overscroll-behavior: contain; scroll-behavior: smooth;
}
.pm { max-width: 86%; animation: pop .35s var(--ease) both; }
.pm p { padding: 10px 12px; border-radius: 14px; font-size: 14px; line-height: 1.45; }
.pm-agent { align-self: flex-start; }
.pm-agent p { background: var(--paper); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.pm-user { align-self: flex-end; }
.pm-user p { background: var(--a); color: #fff; border-bottom-right-radius: 4px; }
.pm-tool {
  align-self: stretch; max-width: 100%;
  display: grid; grid-template-columns: 14px minmax(0, 1fr) auto; gap: 8px; align-items: center;
  padding: 7px 10px; border-radius: 8px;
  background: var(--a-soft); font-family: var(--mono); font-size: 11px; color: var(--ink-2);
}
.pm-tool code { overflow-wrap: anywhere; }
.pm-tool .out { color: var(--ink); font-weight: 600; white-space: nowrap; }
.pm-tool .st {
  width: 12px; height: 12px; border-radius: 50%;
  border: 1.5px solid var(--a); border-right-color: transparent; animation: spin .7s linear infinite;
}
.pm-tool.done .st { border: 0; animation: none; background: var(--a); -webkit-mask: var(--tick) center / 12px no-repeat; mask: var(--tick) center / 12px no-repeat; }
.pm-tool.is-guard { background: color-mix(in srgb, var(--r) 14%, transparent); }
.pm-tool.is-guard .st { border-color: var(--r); border-right-color: transparent; }
.pm-tool.is-guard.done .st { background: var(--r); }
:root { --tick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.2l2.2 2.2 4.8-4.8' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
.pm-typing { align-self: flex-start; display: inline-flex; gap: 4px; padding: 12px 14px; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; border-bottom-left-radius: 4px; }
.pm-typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-3); animation: bob 1s ease-in-out infinite; }
.pm-typing i:nth-child(2) { animation-delay: .15s; }
.pm-typing i:nth-child(3) { animation-delay: .3s; }
.pm-cta { align-self: flex-start; }
.phone-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 14px 16px; border-top: 1px solid var(--line); background: var(--paper); }
.phone-chips-k { width: 100%; font-size: 11.5px; color: var(--ink-3); margin-bottom: 2px; }
.chip {
  border: 1px solid var(--line-2); background: var(--paper); border-radius: 999px;
  padding: 7px 12px; font-size: 12.5px; font-weight: 500; text-align: left;
  transition: border-color .2s, background-color .2s, transform .2s var(--ease);
}
.chip:hover { border-color: var(--a); color: var(--a); transform: translateY(-1px); }
.chip:disabled { opacity: .45; cursor: default; transform: none; }
.chip.chip-solid { background: var(--a); color: #fff; border-color: var(--a); }

@keyframes pop { from { opacity: 0; transform: translateY(6px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes bob { 0%, 100% { transform: translateY(0); opacity: .4; } 50% { transform: translateY(-3px); opacity: 1; } }

/* ---------- Metrics ---------- */
.f-head-c { flex-direction: column; justify-content: center; text-align: center; gap: 8px; }
.f-sub { color: var(--ink-3); font-size: 14.5px; }
.growth { display: grid; gap: 18px; max-width: 860px; margin: 8px auto 0; }
.gr { display: grid; grid-template-columns: 170px minmax(0, 1fr) 96px 56px; align-items: center; gap: 16px; }
.gr-k { font-weight: 600; font-size: 15px; line-height: 1.2; }
.gr-k small { display: block; font-weight: 400; font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
.gr-track { position: relative; height: 36px; border-radius: 8px; background: var(--paper-2); overflow: hidden; }
.gr-fill {
  position: absolute; inset: 0; border-radius: 8px; background: var(--a);
  transform: scaleX(var(--p)); transform-origin: left; transition: transform 1.2s var(--ease) .15s;
}
.growth.is-in .gr-fill { transform: scaleX(1); }
.gr:nth-child(2) .gr-fill { transition-delay: .3s; }
.gr:nth-child(3) .gr-fill { transition-delay: .45s; }
.gr:nth-child(4) .gr-fill { transition-delay: .6s; }
/* the grey "then" stub sits on top of the fill so where it started stays visible */
.gr-from {
  position: absolute; z-index: 1; inset: 0 auto 0 0; width: calc(var(--p) * 100%); min-width: max-content;
  display: flex; align-items: center; padding: 0 10px; border-radius: 8px 0 0 8px;
  background: var(--line-2); color: var(--ink); font-family: var(--mono); font-size: 12px; white-space: nowrap;
}
.gr-to { font-family: var(--display); font-weight: 700; font-size: 2rem; line-height: 1; letter-spacing: -.03em; text-align: right; font-variant-numeric: tabular-nums; }
.gr-x { justify-self: start; padding: 3px 8px; border-radius: 999px; background: color-mix(in srgb, var(--a) 14%, transparent); color: var(--a); font-weight: 700; font-size: 13px; }
.gr-foot { display: grid; gap: 6px; justify-items: center; margin-top: 28px; text-align: center; color: var(--ink-2); font-size: 15px; }
.gr-foot b { color: var(--ink); }

/* ---------- Principles stickies ---------- */
.frame-open .frame-label { margin-bottom: 14px; }
.stickies { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.sticky {
  display: grid; gap: 10px; align-content: start;
  min-height: 220px; padding: 20px 20px 18px;
  background: var(--c); color: var(--sticky-ink);
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 10px 22px -6px rgb(0 0 0 / 20%);
  transform: rotate(var(--r, 0deg));
  transition: box-shadow .2s var(--ease), transform .2s var(--ease);
  touch-action: none;
}
.sticky-t { font-family: var(--hand); font-variation-settings: "INFM" 50; font-weight: 700; font-size: 26px; line-height: 1.15; }
.sticky-b { font-family: var(--hand); font-variation-settings: "INFM" 30; font-size: 18px; line-height: 1.35; }
.sticky-src { font-family: var(--mono); font-size: 10.5px; opacity: .6; margin-top: auto; }

/* ---------- Beyond ---------- */
.beyond { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.b-item { display: grid; gap: 4px; align-content: start; }
.b-num { font-family: var(--display); font-weight: 800; font-size: clamp(2.2rem, 5cqi, 3rem); line-height: 1; letter-spacing: -.035em; }
.b-k { font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.b-item > p:last-child { color: var(--ink-2); font-size: 14.5px; margin-top: 6px; }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.email-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 18px; }
.email { font-family: var(--mono); font-size: 14px; user-select: all; overflow-wrap: anywhere; }
.links-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.note-card {
  background: var(--c); color: var(--sticky-ink); padding: 18px;
  transform: rotate(1.5deg); box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 14px 26px -8px rgb(0 0 0 / 22%);
  display: grid; gap: 12px;
}
.note-card textarea {
  width: 100%; resize: vertical; border: 0; background: transparent; outline: none; color: var(--sticky-ink);
  font-family: var(--hand); font-variation-settings: "INFM" 40; font-size: 18px; line-height: 1.4;
}
.note-card textarea::placeholder { color: rgb(29 27 22 / 50%); }
.note-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.note-count { font-family: var(--mono); font-size: 10.5px; opacity: .65; }
.note-card .btn-primary { background: var(--sticky-ink); border-color: var(--sticky-ink); color: #fff; }

/* =========================================================
   Dock: tools + Ask Ananya
   ========================================================= */
.dock {
  position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 60;
  transform: translateX(-50%);
  display: flex; align-items: center; gap: 8px;
  padding: 6px; border-radius: 14px;
  background: var(--chrome); border: 1px solid var(--chrome-line); box-shadow: var(--shadow-lg);
  width: min(560px, calc(100% - 32px));
}
.tools { gap: 2px; padding-right: 6px; border-right: 1px solid var(--chrome-line); }
.tool { display: grid; place-items: center; width: 38px; height: 38px; border: 0; border-radius: 9px; background: transparent; }
.tool svg { width: 18px; height: 18px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.tool[data-tool="move"] svg { fill: var(--ink); }
.tool:hover { background: var(--paper-2); }
.tool.is-on { background: var(--sel); }
.tool.is-on svg { stroke: #fff; }
.tool.is-on[data-tool="move"] svg { fill: #fff; }
.ask { flex: 1; display: flex; align-items: center; gap: 8px; min-width: 0; padding: 0 6px; }
.ask-av { width: 28px; height: 28px; flex: none; }
.ask input { flex: 1; min-width: 0; height: 38px; border: 0; background: transparent; outline: none; font-size: 14px; }
.ask input::placeholder { color: var(--ink-3); }
.ask-kbd { font-size: 11px; color: var(--ink-3); border: 1px solid var(--chrome-line); border-radius: 5px; padding: 1px 6px; }

/* =========================================================
   Cursors + bubble (screen space)
   ========================================================= */
.cursor {
  position: absolute; left: 0; top: 0; pointer-events: none;
  transform: translate(var(--sx, -100px), var(--sy, -100px));
  will-change: transform;
}
.cursor svg { width: 20px; height: 20px; display: block; filter: drop-shadow(0 1px 1.5px rgb(0 0 0 / 25%)); }
.cursor svg path { stroke: #fff; stroke-width: 1.4; stroke-linejoin: round; }
.cursor-name {
  position: absolute; left: 16px; top: 18px; white-space: nowrap;
  color: #fff; font-size: 11.5px; font-weight: 600; padding: 3px 8px; border-radius: 6px 6px 6px 2px;
}
.cursor-r svg path { fill: var(--r); }
.cursor-r .cursor-name { background: var(--r); }
.cursor-a > svg path { fill: var(--dobby); }
.cursor-a .cursor-name { background: var(--dobby); }
.cursor.is-away { opacity: 0; transition: opacity .4s; }

.bubble {
  position: absolute; left: 16px; top: 46px; width: min(330px, calc(100vw - 32px));
  pointer-events: auto;
  background: var(--chrome); color: var(--ink);
  border: 1px solid var(--chrome-line); border-radius: 4px 14px 14px 14px;
  box-shadow: var(--shadow-lg); padding: 14px 14px 12px;
  animation: pop .3s var(--ease) both;
}
.cursor-a.flip .bubble { left: auto; right: -4px; border-radius: 14px 4px 14px 14px; }
.cursor-a.lift .bubble { top: auto; bottom: 12px; }
.bubble-text { font-size: 14px; line-height: 1.5; min-height: 1.5em; }
.bubble-text .w { transition: opacity .2s; }
.bubble-text .w.off { opacity: 0; }
.bubble-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; }
.bubble-actions:empty { display: none; }
.bubble-actions .step { font-family: var(--mono); font-size: 11px; color: var(--ink-3); margin-right: auto; }
.b-btn { border: 1px solid var(--chrome-line); background: var(--chrome); border-radius: 8px; padding: 6px 10px; font-size: 12.5px; font-weight: 600; }
.b-btn:hover { border-color: var(--ink-3); }
.b-btn.b-primary { background: var(--dobby); border-color: var(--dobby); color: #fff; }
.bubble-who { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; font-size: 12.5px; }
.bubble-who svg { width: 26px; height: 26px; flex: none; }
.bubble-who b { font-weight: 700; }
.bubble-who span { color: var(--ink-3); font-size: 11.5px; }

.toast {
  position: fixed; left: 50%; top: calc(var(--topbar) + 14px); z-index: 70; transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ink); color: var(--paper); font-size: 13px; font-weight: 500;
  padding: 8px 14px; border-radius: 999px; box-shadow: var(--shadow-lg);
  animation: pop .3s var(--ease) both;
}

/* =========================================================
   BOARD MODE
   ========================================================= */
.app.board { position: fixed; inset: 0; display: grid; grid-template-rows: var(--topbar) minmax(0, 1fr); overflow: hidden; }
.app.board .topbar { position: relative; top: 0; }
.app.board .board-only { display: flex; }
.app.board .viewport {
  overflow: hidden; touch-action: none; cursor: default;
  background-color: var(--canvas);
  background-image: radial-gradient(var(--dot) calc(1.1px * var(--dz, 1)), transparent calc(1.2px * var(--dz, 1)));
  background-size: var(--gs, 24px) var(--gs, 24px);
  background-position: var(--gx, 0) var(--gy, 0);
}
.app.board.tool-hand .viewport, .app.board.space .viewport { cursor: grab; }
.app.board.panning .viewport { cursor: grabbing; }
.app.board.tool-sticky .viewport { cursor: crosshair; }

.app.board .world {
  position: absolute; left: 0; top: 0; display: block;
  max-width: none; margin: 0; padding: 0; width: 0; height: 0;
  transform-origin: 0 0;
  user-select: none; -webkit-user-select: none;
}
.app.board .world textarea, .app.board .world input { user-select: text; -webkit-user-select: text; }
.app.board .frame { position: absolute; left: var(--fx); top: var(--fy); width: var(--fw); }
.app.board .frame-label {
  font-size: calc(12px / var(--z, 1));
  margin-bottom: calc(8px / var(--z, 1));
  transform-origin: left bottom;
}
.app.board .frame.is-focus .frame-label { color: var(--sel); }
.app.board .connectors { display: block; position: absolute; overflow: visible; left: 0; top: 0; width: 1px; height: 1px; pointer-events: none; }
.connectors path { fill: none; stroke: var(--ink-3); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.connectors text { fill: var(--ink-2); font-family: var(--hand); font-size: 22px; font-variation-settings: "INFM" 60; }

.app.board .hand { position: absolute; display: block; white-space: nowrap; font-size: 22px; }
.app.board .hand-arrow { position: absolute; display: block; }
.hand-hello { left: -300px; top: 150px; transform: rotate(-4deg); }
.arrow-hello { left: -120px; top: 200px; width: 120px; height: 80px; }
.hand-chakr { left: -190px; top: 500px; transform: rotate(-5deg); color: var(--r); }
.hand-phone { right: 380px; top: -40px; transform: rotate(-3deg); color: var(--a); }
.hand-play { right: 20px; top: -50px; transform: rotate(-3deg); color: var(--dobby); }

/* board: principles stickies float freely */
.app.board .stickies { position: relative; display: block; height: 380px; }
.app.board .sticky { position: absolute; left: var(--x); top: var(--y); width: 420px; min-height: 160px; cursor: grab; }
.app.board .sticky:hover { box-shadow: 0 2px 2px rgb(0 0 0 / 6%), 0 18px 32px -8px rgb(0 0 0 / 28%); }
.app.board .sticky.is-dragging { cursor: grabbing; transform: rotate(0deg) scale(1.04); z-index: 5; box-shadow: 0 30px 50px -12px rgb(0 0 0 / 35%); transition: none; }

/* visitor stickies */
.v-sticky {
  position: absolute; width: 220px; min-height: 180px; padding: 12px 14px 14px;
  background: var(--c); color: var(--sticky-ink);
  box-shadow: 0 1px 1px rgb(0 0 0 / 6%), 0 12px 24px -6px rgb(0 0 0 / 24%);
  display: grid; grid-template-rows: auto 1fr; gap: 6px;
  animation: pop .3s var(--ease) both; touch-action: none; cursor: grab;
}
.v-sticky-top { display: flex; align-items: center; justify-content: space-between; font-family: var(--mono); font-size: 10.5px; opacity: .7; }
.v-sticky-top button { border: 0; background: transparent; font-size: 16px; line-height: 1; padding: 2px 4px; color: var(--sticky-ink); }
.v-sticky textarea { width: 100%; height: 100%; min-height: 130px; border: 0; resize: none; background: transparent; outline: none; color: var(--sticky-ink); font-family: var(--hand); font-size: 17px; line-height: 1.35; cursor: text; }
.v-sticky.is-dragging { cursor: grabbing; box-shadow: 0 30px 50px -12px rgb(0 0 0 / 35%); }
.app:not(.board) .v-sticky { display: none; }

/* panel */
.app.board .panel {
  display: grid; grid-template-rows: auto 1fr auto; gap: 6px;
  position: absolute; left: 12px; top: calc(var(--topbar) + 12px); z-index: 40; width: 208px;
  padding: 12px 8px 10px; border-radius: 12px;
  background: var(--chrome); border: 1px solid var(--chrome-line); box-shadow: var(--shadow);
}
.panel-head { font-size: 12px; font-weight: 600; color: var(--ink-3); padding: 0 8px 4px; }
.panel-list { display: grid; gap: 1px; }
.panel-list button {
  display: flex; align-items: center; gap: 10px; width: 100%;
  border: 0; background: transparent; text-align: left; padding: 7px 8px; border-radius: 7px;
  font-size: 13px; color: var(--ink-2);
}
.panel-list button::before { content: "#"; font-family: var(--mono); color: var(--ink-3); font-size: 12px; }
.panel-list button:hover { background: var(--paper-2); color: var(--ink); }
.panel-list button.is-on { background: color-mix(in srgb, var(--sel) 12%, transparent); color: var(--sel); font-weight: 600; }
.panel-list button.is-on::before { color: var(--sel); }
.panel-foot { font-size: 11px; color: var(--ink-3); padding: 8px 8px 0; border-top: 1px solid var(--chrome-line); line-height: 1.6; }
.panel-foot kbd { font-size: 10px; border: 1px solid var(--chrome-line); border-radius: 4px; padding: 0 4px; }

/* zoom + minimap */
.app.board .zoombox {
  display: flex; position: absolute; right: 12px; bottom: calc(16px + 132px + 10px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  background: var(--chrome); border: 1px solid var(--chrome-line); border-radius: 10px; box-shadow: var(--shadow); overflow: hidden;
}
.zoombox button { border: 0; background: transparent; height: 34px; min-width: 34px; font-size: 16px; }
.zoombox button:hover { background: var(--paper-2); }
.zoom-v { font-family: var(--mono); font-size: 12px !important; min-width: 58px !important; border-inline: 1px solid var(--chrome-line) !important; }
.app.board .minimap {
  display: block; position: absolute; right: 12px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  width: 200px; height: 132px; border-radius: 10px; overflow: hidden; cursor: pointer;
  background: var(--chrome); border: 1px solid var(--chrome-line); box-shadow: var(--shadow);
}
.mm-frame { position: absolute; background: var(--line-2); border-radius: 1px; }
.mm-frame.is-open { background: transparent; outline: 1px dashed var(--line-2); }
.mm-view { position: absolute; border: 1.5px solid var(--sel); background: color-mix(in srgb, var(--sel) 10%, transparent); border-radius: 2px; }

.app.board .cursors { display: block; position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 30; }

/* page mode shows Ananya's bubble docked above the ask field */
.app:not(.board) .cursors { display: block; position: fixed; inset: auto 0 calc(84px + env(safe-area-inset-bottom, 0px)) 0; height: 0; z-index: 61; }
.app:not(.board) .cursor-r, .app:not(.board) .cursor-a > svg, .app:not(.board) .cursor-a > .cursor-name { display: none; }
.app:not(.board) .cursor-a { transform: none; left: 16px; right: 16px; top: auto; bottom: 0; opacity: 1; }
.app:not(.board) .bubble { position: absolute; left: 0 !important; right: 0; top: auto; bottom: 0; margin-inline: auto; width: auto; max-width: 420px; border-radius: 14px; }

/* =========================================================
   Container-driven layout for narrow frames (page mode, phones)
   ========================================================= */
@container (max-width: 1180px) {
  .duo { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .duo-mid { grid-column: 1 / -1; grid-row: 2; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 0; }
  .duo-mid .story-state { grid-column: 1 / -1; }
}
@container (max-width: 820px) {
  .minis-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .crew { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .flow { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px 22px; }
  .node { grid-column: auto; grid-row: auto; min-height: 0; }
  .prd { grid-template-columns: 1fr; }
  .phone { height: 560px; }
  .gr { grid-template-columns: 130px minmax(0, 1fr) 76px 48px; gap: 12px; }
  .gr-to { font-size: 1.5rem; }
  .minis-wide { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact { grid-template-columns: 1fr; }
}
@container (max-width: 700px) {
  .duo { grid-template-columns: 1fr; }
  .duo-mid { grid-row: auto; grid-template-columns: 1fr; }
  #phone-ananya { order: 3; }
  .duo .phone { height: 520px; }
  .polaroid { top: -14px; left: auto; right: -4px; width: 104px; padding: 6px 6px 22px; }
  .polaroid figcaption { font-size: 11.5px; bottom: 4px; }
  .polaroid::before { width: 48px; height: 14px; margin-left: -24px; top: -7px; }
  .paper-hello.has-photo .ui-tag { max-width: calc(100% - 104px); }
  .polaroid .stamp-photo { left: -14px; bottom: 30px; top: auto; right: auto; padding: 3px 8px 4px; font-size: 7px; border-width: 2px; }
  .polaroid .stamp-photo small { font-size: 6.5px; }
  .polaroid .stamp-photo b { font-size: .9rem; }
}
@container (max-width: 640px) {
  .stamp { right: 12px; top: 92px; padding: 5px 10px 6px; font-size: 8.5px; border-width: 2.5px; }
  .stamp b { font-size: 1.45rem; }
  .receipts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .stickies { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .beyond { grid-template-columns: 1fr; }
  .notes-hand { grid-template-columns: 1fr; }
  .rm-lane { grid-template-columns: 92px minmax(0, 1fr); }
  .rm-axis { left: 92px; }
  .rm-axis span:nth-child(odd) { visibility: hidden; }
  .rm-bar { font-size: 11.5px; padding: 0 6px; }
}
@container (max-width: 460px) {
  .badge { height: 270px; }
  .stickies { grid-template-columns: 1fr; }
  .minis, .minis-wide { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .mini { padding: 12px; font-size: 12px; }
  .mini b { font-size: 1.15rem; }
  .gr { grid-template-columns: minmax(0, 1fr) 80px 50px; gap: 6px 10px; }
  .gr-k { grid-column: 1 / -1; }
  .gr-track { height: 28px; }
  .sticky { min-height: 0; }
}

@media (max-width: 1100px) {
  .app.board .panel { display: none; }
}
@media (max-width: 720px) {
  .crumbs, .presence { display: none; }
  .tb-btn { padding-inline: 10px; }
  .app.board .minimap { display: none; }
  .app.board .zoombox { bottom: calc(84px + env(safe-area-inset-bottom, 0px)); }
  .ask-kbd { display: none; }
}
@media (max-width: 420px) {
  .tb-tour { display: none; }
  .tb-btn { padding-inline: 9px; font-size: 12.5px; }
}
@media (max-width: 720px) {
  .app:not(.board) .bubble { padding: 12px 12px 10px; }
  .app:not(.board) .bubble-text { font-size: 13.5px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}
