/* The demo's own chrome: one pill and one nudge. Everything else on the page
   is the Vault's. Uses the Vault's own colour tokens so every Vault theme
   (and dark/light) keeps it legible. */
.demo-pill {
    position: fixed; right: 16px; bottom: 16px; z-index: 99990;
    display: flex; align-items: center; gap: 10px;
    padding: 7px 8px 7px 14px; border-radius: 999px;
    background: var(--bg-secondary, #151a24); color: var(--text-primary, #e8ecf3);
    border: 1px solid var(--border-color, rgba(255,255,255,.12));
    box-shadow: 0 8px 28px rgba(0,0,0,.35);
    font: 500 12.5px/1.2 'DM Sans', system-ui, sans-serif;
}
.demo-pill-dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e;
    box-shadow: 0 0 0 3px rgba(34,197,94,.18); flex: none; }
.demo-pill-text b { font-weight: 700; }
.demo-pill-join {
    padding: 6px 12px; border-radius: 999px; text-decoration: none; white-space: nowrap;
    background: var(--cmd-accent, #4a9eff); color: #fff; font-weight: 700;
}
.demo-pill-join:hover { filter: brightness(1.1); }
.demo-nudge {
    position: fixed; left: 50%; bottom: 70px; z-index: 99991;
    transform: translate(-50%, 12px); opacity: 0; pointer-events: none;
    max-width: min(560px, calc(100vw - 32px)); padding: 12px 16px; border-radius: 10px;
    background: var(--bg-secondary, #151a24); color: var(--text-primary, #e8ecf3);
    border: 1px solid var(--cmd-accent, #4a9eff);
    box-shadow: 0 10px 32px rgba(0,0,0,.4);
    font: 400 13.5px/1.45 'DM Sans', system-ui, sans-serif;
    transition: opacity .18s ease, transform .18s ease;
}
.demo-nudge.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.demo-nudge a { color: var(--cmd-accent, #4a9eff); font-weight: 700; margin-left: 4px; }
@media (max-width: 767px) {
    .demo-pill { left: 12px; right: 12px; bottom: 12px; justify-content: space-between; }
    .demo-pill-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .demo-nudge { bottom: 76px; }
}

/* The gap database is view-only in the demo (Kyle 2026-10-07). A press
   release cell keeps its headline, marked with a lock; a cell with nothing
   but "Click to load" says Members only instead. demo-shim.js stops the
   click either way. */
a.fwd-stat-link[data-col-idx="67"][title]::after { content: ' 🔒'; font-size: 0.9em; }
a.fwd-stat-link[data-col-idx="67"], a.fwd-stat-link[data-col-idx="34"] {
    text-decoration: none !important; cursor: help;
}
a.fwd-stat-link[data-col-idx="67"]:not([title]), a.fwd-stat-link[data-col-idx="34"],
a.fwd-stat-link[data-col-name="Transcript"] { font-size: 0 !important; }
a.fwd-stat-link[data-col-idx="67"]:not([title])::after, a.fwd-stat-link[data-col-idx="34"]::after,
a.fwd-stat-link[data-col-name="Transcript"]::after {
    content: '🔒 Members only'; font-size: 11.5px; color: var(--text-muted, #71717a);
}

/* Desk-only and members-only corners of the database. */
button.database-subtab[data-db-tab="parabolic"] { display: none !important; }
button[data-db-view="charts"]::after, #dbChartToggleBtn::after { content: ' 🔒'; font-size: 0.85em; }

/* The teaser fold (demo-fold.js): the first rows of a list stay clear, the
   rest blur under a lock band. */
.demo-blur {
    filter: blur(4px) saturate(0.6); opacity: 0.55;
    pointer-events: none !important; user-select: none !important;
}
tr.demo-fold > td { padding: 0 !important; border: 0 !important; background: transparent !important; }
.demo-fold { grid-column: 1 / -1; }
.demo-fold-inner {
    display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap;
    margin: 8px 0; padding: 12px 16px; border-radius: 10px;
    background: var(--bg-secondary, #131316); color: var(--text-primary, #fafafa);
    border: 1px solid var(--cmd-accent, #4a9eff);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.35);
    font: 500 13px/1.4 'DM Sans', system-ui, sans-serif; white-space: normal;
    position: sticky; left: 8px; max-width: min(720px, calc(100vw - 120px));
}
.demo-fold-lock { font-size: 15px; }
.demo-fold-join {
    padding: 5px 12px; border-radius: 999px; text-decoration: none; white-space: nowrap;
    background: var(--cmd-accent, #4a9eff); color: #fff !important; font-weight: 700; font-size: 12px;
}

/* Stream recordings are members' content: listed, not playable. */
article.library-card { cursor: default !important; }
article.library-card .library-card-thumb { position: relative; }
article.library-card .library-card-thumb::after {
    content: '🔒'; position: absolute; top: 8px; left: 8px;
    padding: 3px 7px; border-radius: 999px; font-size: 12px;
    background: rgba(0, 0, 0, 0.6);
}

/* The forward tester's win/loss strip: it counts every gap the tester logs,
   not picks, and reads as a track record out of context (Kyle 2026-10-08). */
.fwd-snapshot { display: none !important; }

/* No copying out of the demo: the cell pop-up's Copy, the small charts'
   Copy / PNG / Book, and the main chart's Snap (to a note) and Book (to the
   Journal). demo-shim.js refuses the clipboard itself. */
.cell-tooltip-copy, .vault-chart-export,
#noteShot, #bookShot, [id*="copyShot"], [id*="saveShot"] { display: none !important; }

/* Out of the demo: Help (its text predates the current Vault) and the
   widgets that cannot work on a frozen slice -- Receipts (the screener's
   live record), Notes and Watchlist (a member's own). */
.rail-btn[onclick*="showHelpModal"] { display: none !important; }
.ws-add[onclick*="'receipts'"], .ws-add[onclick*="'notes'"], .ws-add[onclick*="'watchlist'"] { display: none !important; }

/* Out of the demo's rail: Journal (a member's own notebook starts empty and
   cannot save here), Alerts (needs an account), Refresh (a frozen day has
   nothing to refresh). */
.rail-btn[data-page="modelbook"], .nav-tab[data-page="modelbook"],
#alertsBellWrap, .rail-foot { display: none !important; }


/* The guided tour (demo-tour.js). The tip sits beside its target; the ring
   outlines the target and lets every click through. */
.demo-tour {
    position: fixed; z-index: 99993; width: 300px;
    padding: 12px 14px; border-radius: 10px;
    background: var(--bg-secondary, #131316); color: var(--text-primary, #fafafa);
    border: 1px solid var(--cmd-accent, #4a9eff);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55);
    font: 400 13.5px/1.45 'DM Sans', system-ui, sans-serif;
    animation: demo-tour-in .2s ease-out;
}
.demo-tour b { font-weight: 700; }
.demo-tour::before {
    content: ''; position: absolute; width: 12px; height: 12px;
    background: inherit; border: inherit; border-right: 0; border-bottom: 0;
}
.demo-tour--right::before { left: -7px; top: calc(var(--arrow-y, 24px) - 6px); transform: rotate(-45deg); }
.demo-tour--left::before { right: -7px; top: calc(var(--arrow-y, 24px) - 6px); transform: rotate(135deg); }
.demo-tour.demo-tour--below::before { top: -7px; left: calc(var(--arrow-x, 24px) - 6px); right: auto; transform: rotate(45deg); }
.demo-tour-count {
    color: var(--cmd-accent, #4a9eff); font: 700 11px/1 'DM Sans', sans-serif;
    letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 6px;
}
.demo-tour-actions { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.demo-tour-skip {
    margin-right: auto; background: none; border: 0; padding: 4px 0; cursor: pointer;
    color: var(--text-muted, #71717a); font: 500 12px 'DM Sans', sans-serif;
}
.demo-tour-skip:hover { color: var(--text-primary, #fafafa); }
.demo-tour-go, .demo-tour-join {
    padding: 6px 14px; border-radius: 999px; border: 0; cursor: pointer; text-decoration: none;
    background: var(--cmd-accent, #4a9eff); color: #fff; font: 700 12px 'DM Sans', sans-serif;
}
.demo-tour-join { background: transparent; border: 1px solid var(--cmd-accent, #4a9eff); color: var(--text-primary, #fafafa); }
.demo-tour-ring {
    position: fixed; z-index: 99992; pointer-events: none;
    border: 2px solid var(--cmd-accent, #4a9eff); border-radius: 8px;
    box-shadow: 0 0 0 4px rgba(74, 158, 255, 0.18);
    animation: demo-tour-pulse 1.6s ease-in-out infinite;
}
@keyframes demo-tour-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes demo-tour-pulse { 0%, 100% { box-shadow: 0 0 0 3px rgba(74, 158, 255, 0.15); } 50% { box-shadow: 0 0 0 8px rgba(74, 158, 255, 0.05); } }
.demo-pill-tour {
    background: none; border: 1px solid var(--cmd-accent, #4a9eff); border-radius: 999px;
    padding: 5px 11px; cursor: pointer; white-space: nowrap;
    color: var(--text-primary, #fafafa); font: 700 12px 'DM Sans', sans-serif;
}
@media (max-width: 899px) { .demo-pill-tour { display: none; } }
.demo-pill-tour:hover { color: var(--text-primary, #fafafa); }
.demo-tour--above::before { bottom: -7px; top: auto; left: calc(var(--arrow-x, 24px) - 6px); transform: rotate(225deg); }
.demo-tour--below::before { top: -7px; left: calc(var(--arrow-x, 24px) - 6px); transform: rotate(45deg); }
.demo-tour--inside::before { display: none; }
.demo-tour-menu {
    position: fixed; z-index: 99994; min-width: 200px; padding: 8px;
    background: var(--bg-secondary, #131316); border: 1px solid var(--border-color, #27272a);
    border-radius: 10px; box-shadow: 0 14px 40px rgba(0, 0, 0, 0.5);
}
.demo-tour-menu-title {
    padding: 4px 8px 8px; color: var(--text-muted, #71717a);
    font: 700 11px 'DM Sans', sans-serif; letter-spacing: 0.08em; text-transform: uppercase;
}
.demo-tour-menu button {
    display: block; width: 100%; padding: 8px 10px; border: 0; border-radius: 6px; text-align: left;
    background: none; color: var(--text-primary, #fafafa); font: 600 13px 'DM Sans', sans-serif; cursor: pointer;
}
.demo-tour-menu button:hover { background: var(--bg-tertiary, #18181c); }

/* Framed on the homepage: the site's chat bubble sits bottom-right. */
.demo-embedded .demo-pill { right: auto; left: 72px; }
