/* The "get the app" box (community/_app_lightbox.html) — ONE stylesheet for the
   community (founder 2026-11-17) and for the Desk and the public pages (founder
   2026-11-22), which do not load community.css. Plain CSS, no build step.

   The community draws the frame (`cm-offers-sheet`), the buttons and the colours
   from its own shell. A page outside it wears `tp-app-box--site`: the same
   frame, buttons and day colours, said here once. On a creative page in night
   colours (html[data-theme="dark"]) the box follows: those values are in
   static/css/creative-night.css; the QR code keeps its white plate. */
dialog.tp-app-box--site {
  --cm-surface: #ffffff; --cm-page: #f7f5f5; --cm-fg: #0b0b0e; --cm-dim: #67676e;
  --cm-divider: #e4e6ee; --cm-track-strong: #d6d4d9; --cm-accent: #0b0b0e;
  --cm-accent-light: #38383e; --cm-cta: #D85A30; --cm-cta-dark: #BF4C27;
  position: fixed; inset: 0; margin: auto; width: min(480px, calc(100% - 32px));
  max-height: calc(100dvh - 32px); overflow-y: auto; box-sizing: border-box; padding: 22px 20px 18px;
  border: 1px solid var(--cm-divider); border-radius: 20px; background: var(--cm-surface);
  color: var(--cm-fg); box-shadow: 0px 9px 32px 0px rgba(11, 11, 14, 0.08);
  font-family: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif; text-align: left; }
dialog.tp-app-box--site:not([open]) { display: none; }
dialog.tp-app-box--site::backdrop { background: rgba(11, 11, 14, .35); backdrop-filter: blur(3px); }
.tp-app-box--site .cm-offers-sheet-close { position: absolute; top: 10px; right: 12px; width: 32px; height: 32px;
  border: 0; border-radius: 50%; background: transparent; color: var(--cm-dim); font-size: 22px; line-height: 1;
  cursor: pointer; }
.tp-app-box--site .cm-btn { display: inline-flex; align-items: center; gap: 7px; border-radius: 50vh;
  font-weight: 700; font-family: inherit; cursor: pointer; border: 1.5px solid var(--cm-divider);
  background: var(--cm-surface); text-decoration: none; }
.tp-app-box--site .cm-btn.cta { background: var(--cm-cta); border-color: var(--cm-cta); color: #fff; }
.tp-app-box--site .cm-btn.cta:hover { background: var(--cm-cta-dark); border-color: var(--cm-cta-dark); }
@media (max-width: 640px) {
  dialog.tp-app-box--site { inset: auto 0 0 0; margin: 0; width: 100%; max-width: none; max-height: 86dvh;
    border-radius: 20px 20px 0 0; border-width: 1px 0 0; padding-bottom: calc(18px + env(safe-area-inset-bottom)); }
}

/* "Get the app" lightbox on every new community visit (founder 2026-11-17,
   community/_app_lightbox.html). The cm-offers-sheet frame; phone = bottom
   sheet straight to the store, desktop = QR code + both stores. */
.tp-app-box-grabber { display: block; width: 36px; height: 4px; margin: -8px auto 14px;
  border-radius: 2px; background: var(--cm-track-strong); }
.tp-app-box--desktop .tp-app-box-grabber { display: none; }
.tp-app-box-icon { display: flex; align-items: center; justify-content: center; width: 52px; height: 52px;
  margin: 0 0 12px; border-radius: 13px; background: var(--cm-page); box-shadow: inset 0 0 0 1px var(--cm-divider); }
.tp-app-box-icon img { width: 30px; height: auto; }
.tp-app-box-title { margin: 0 36px 6px 0; font-family: 'Playfair Display', Georgia, serif; font-size: 22px;
  font-weight: 700; line-height: 1.2; text-wrap: balance; }
.tp-app-box-body { margin: 0; font-size: 14px; line-height: 1.45; color: var(--cm-dim); }
.tp-app-box-perks { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px;
  font-size: 13.5px; color: var(--cm-accent-light); }
.tp-app-box-perks li { display: flex; align-items: center; gap: 10px; }
.tp-app-box-perks svg { flex: 0 0 18px; width: 18px; height: 18px; fill: none; stroke: var(--cm-cta);
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.tp-app-box-actions { display: flex; flex-direction: column; gap: 10px; margin: 18px 0 0; }
.tp-app-box-actions .cm-btn { justify-content: center; width: 100%; box-sizing: border-box; padding: 12px 20px;
  font-size: 14px; }
.tp-app-box-open { color: var(--cm-fg); }
.tp-app-box-web { display: block; margin: 14px auto 0; padding: 4px 8px; border: 0; background: transparent;
  font: inherit; font-size: 13px; color: var(--cm-dim); text-decoration: underline;
  text-underline-offset: 3px; cursor: pointer; }
.tp-app-box-split { display: flex; gap: 20px; align-items: flex-start; }
/* Wide enough for the title on one line beside the QR code. */
dialog.tp-app-box--desktop { width: min(540px, calc(100% - 32px)); }
.tp-app-box--desktop .tp-app-box-title { margin-right: 0; text-wrap: wrap; }
/* Keep the × clear of the QR frame's corner. */
.tp-app-box--desktop .tp-app-box-split { padding-right: 26px; }
.tp-app-box-copy { flex: 1 1 auto; min-width: 0; }
.tp-app-box-qr { flex: 0 0 132px; margin: 6px 0 0; text-align: center; }
.tp-app-box-qr-frame { position: relative; display: block; width: 132px; height: 132px; box-sizing: border-box;
  padding: 6px; border-radius: 14px; background: #fff; box-shadow: inset 0 0 0 1.5px var(--cm-divider); }
.tp-app-box-qr-code { display: block; width: 100%; height: 100%; }
.tp-app-box-qr-icon { position: absolute; left: 50%; top: 50%; width: 28px; height: 28px; margin: -14px 0 0 -14px;
  display: flex; align-items: center; justify-content: center; border-radius: 7px; background: var(--cm-page);
  box-shadow: 0 0 0 1px var(--cm-divider); }
.tp-app-box-qr-icon img { width: 17px; height: auto; }
.tp-app-box-qr figcaption { margin: 6px 0 0; font-size: 12px; color: var(--cm-dim); }
.tp-app-box-stores { display: flex; gap: 10px; margin: 18px 0 0; }
.tp-app-box-store { flex: 1 1 0; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 14px; border-radius: 50vh; background: var(--cm-accent); color: #fff; font-size: 13px;
  font-weight: 700; text-decoration: none; }
.tp-app-box-store svg { width: 16px; height: 16px; flex-shrink: 0; }
.tp-app-box-store[data-store="ios"] svg { margin-top: -2px; }
.tp-app-box-store:hover { background: var(--cm-accent-light); }
/* "Do not show again" (founder 2026-11-22): the small second line under
   "Continue on the web", for a signed-in member only. */
.tp-app-box-never { display: block; margin: 6px auto 0; padding: 4px 8px; border: 0; background: transparent;
  font: inherit; font-size: 12px; color: var(--cm-dim); cursor: pointer; }
.tp-app-box-never:hover { text-decoration: underline; text-underline-offset: 3px; }
