/* demo-duesline.css - the landing page's hero demo (render.mjs landingDemo, static/demo-duesline.js): one browser
   window showing Duesline's own dashboard. Linked on the landing page alone, after app.css, so .mx-badge/.mx-field/
   .mx-btn/.mx-note read as they really do. Its tables and headings copy .mx-table's and <h1>'s look under the
   demo's own .dsl-table/.dsl-h1 classes and tags instead of borrowing the real ones - the gate's row and heading
   checks expect every real mx-table row and every <h1> to be the genuine, functioning thing, which a decorative,
   pointer-events:none screen never is.

   The kit's demo frame (.lp-demo > .lp-demo__fit > .lp-demo__stage, landing.css and demo.js) is used as it is:
   nothing here touches it. The window draws its own browser chrome (dots, address bar) the way FleetFault's demo
   does, since the kit has no browser-window furniture of its own. Everything is scoped under .dsl, the demo's own
   class.

   Inside the stage the sizes are px, on purpose: it is a picture of a screen at a fixed design size (1040 x 680),
   which demo.js scales to the column.

   What the tour changes, read here:
     data-view     members | invoices        which page's content shows
     data-overlay  '' | add | level | invoice   which dialog sits over it
     is-added      the new member's row is in the roster
     is-leveled    that member's level badge replaces "No level assigned"
     is-invoiced   the new invoice's row is in the Invoices list (set with is-leveled: the dues are automatic)
     is-reminded   the reminder-sent toast shows, and the Send reminder button hides

   The invoice overlay's Payment link card (.dsl-paycard, a real .mx-card) is in the markup only
   while card payment is switched on (render.mjs landingDemo { cards }); the tour skips it otherwise. */

.dsl-stage {
  width: 1040px;
  height: 680px;
  overflow: hidden;
  color: var(--c-ink);
  font-size: 14px;
  line-height: 1.4;
  text-align: start;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}
.dsl-stage :where(p, ul, li) { margin: 0; }
.dsl-stage ul { padding: 0; list-style: none; }

.dsl-win {
  position: absolute;
  left: 24px;
  top: 24px;
  width: 992px;
  height: 632px;
  overflow: hidden;
  border: 1px solid var(--c-line-strong);
  border-radius: 14px;
  background: var(--c-canvas);
  box-shadow: var(--lp-demo-shadow);
}
.dsl-win__chrome {
  display: flex;
  align-items: center;
  gap: 14px;
  height: 36px;
  padding: 0 14px;
  border-bottom: 1px solid var(--c-line);
  background: var(--c-surface-2);
}
.dsl-dots { display: flex; gap: 6px; }
.dsl-dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--c-line-strong); }
.dsl-url {
  display: flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 8px;
  background: var(--c-canvas);
  color: var(--c-ink-muted);
  font-family: var(--font-mono);
  font-size: 11px;
}
.dsl-appbar {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 52px;
  padding: 0 20px;
  border-bottom: 1px solid var(--c-line);
}
.dsl-mark { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; }
.dsl-mark svg { width: 20px; height: 20px; color: var(--c-accent); }
.dsl-nav { display: flex; gap: 20px; }
.dsl-nav__item { display: inline-flex; align-items: center; gap: 6px; color: var(--c-ink-muted); font-size: 13px; }
.dsl-nav__item svg { width: 15px; height: 15px; opacity: 0.7; }
.dsl-stage[data-view='members'] .dsl-nav__item[data-dsl-nav='members'],
.dsl-stage[data-view='invoices'] .dsl-nav__item[data-dsl-nav='invoices'] { color: var(--c-ink); }
.dsl-stage[data-view='members'] .dsl-nav__item[data-dsl-nav='members'] svg,
.dsl-stage[data-view='invoices'] .dsl-nav__item[data-dsl-nav='invoices'] svg { color: var(--c-accent); opacity: 1; }
.dsl-cog { display: inline-flex; margin-left: auto; color: var(--c-ink-muted); }
.dsl-cog svg { width: 17px; height: 17px; }

.dsl-views { position: relative; height: calc(100% - 88px); padding: 22px 28px; overflow: hidden; }
.dsl-view { display: none; }
.dsl-stage[data-view='members'] .dsl-view--members,
.dsl-stage[data-view='invoices'] .dsl-view--invoices { display: block; }

.dsl-eyebrow { color: var(--c-ink-muted); font-size: 12.5px; }
.dsl-h1 { margin: 2px 0 14px; font-size: 20px; font-weight: 650; }
.dsl-actions { margin-bottom: 14px; }
/* The Dues requests page's quiet line in place of the Run dues cycle button (the dues are automatic). */
.dsl-auto { margin-bottom: 14px; color: var(--c-ink-subtle); font-size: 12.5px; }

.dsl-btn {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--c-line-strong);
  background: var(--c-surface);
  color: var(--c-ink);
}
.dsl-btn--primary { border-color: transparent; background: var(--c-accent); color: var(--c-accent-ink); }
.dsl-btn.lp-pressed { transform: scale(0.96); }

/* A picture of .mx-table, not the real element: the row check (packages/gate) requires every
   mx-table row to open a view, which a decorative, pointer-events:none demo never does. These
   rules copy the kit's .mx-table look (app.css) by hand instead of borrowing its class. */
.dsl-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
.dsl-table th {
  padding: 0 0.875rem 0.5rem 0;
  border-bottom: 1px solid var(--c-line-strong);
  text-align: start;
  font-weight: 600;
  font-size: 0.8125rem;
  color: var(--c-ink-muted);
}
.dsl-table td { padding: 0.75rem 0.875rem 0.75rem 0; border-bottom: 1px solid var(--c-line); color: var(--c-ink); vertical-align: top; }
.dsl-table tr:last-child td { border-bottom: 0; }
.dsl-row--new { opacity: 0.35; }
.dsl-stage.is-added .dsl-view--members .dsl-row--new,
.dsl-stage.is-invoiced .dsl-view--invoices .dsl-row--new { opacity: 1; }
.dsl-level-set { display: none; }
.dsl-stage.is-leveled .dsl-level-none { display: none; }
.dsl-stage.is-leveled .dsl-level-set { display: inline; }

/* The dialogs: a centred card over the window, the way .mx-overlay sits over a real page - simplified to one
   fixed position here since the demo has no real <dialog>. */
.dsl-overlay {
  display: none;
  position: absolute;
  left: 50%;
  top: 50%;
  width: 360px;
  transform: translate(-50%, -50%);
  padding: 18px 20px;
  border-radius: 12px;
  border: 1px solid var(--c-line-strong);
  background: var(--c-surface);
  box-shadow: var(--lp-demo-shadow);
  z-index: 20;
}
.dsl-stage[data-overlay='add'] .dsl-overlay--add,
.dsl-stage[data-overlay='level'] .dsl-overlay--level,
.dsl-stage[data-overlay='invoice'] .dsl-overlay--invoice { display: block; }
.dsl-overlay__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; font-size: 14px; }
.dsl-overlay__close { display: inline-flex; color: var(--c-ink-muted); }
.dsl-overlay__close svg { width: 15px; height: 15px; }
.dsl-overlay .mx-field { margin-bottom: 14px; }
.dsl-overlay .mx-field label { display: block; margin-bottom: 4px; font-size: 12.5px; color: var(--c-ink-muted); }
.dsl-input {
  display: block;
  height: 32px;
  padding: 0 10px;
  border: 1px solid var(--c-line-field, var(--c-line-strong));
  border-radius: 8px;
  background: var(--c-canvas);
  line-height: 32px;
  font-size: 13px;
  color: var(--c-ink);
}

.dsl-select { position: relative; display: block; }
.dsl-select__value {
  display: block;
  height: 32px;
  padding: 0 10px;
  border: 1px solid var(--c-line-field, var(--c-line-strong));
  border-radius: 8px;
  background: var(--c-canvas);
  line-height: 32px;
  font-size: 13px;
}
.dsl-select__list {
  display: none;
  position: absolute;
  left: 0;
  top: 36px;
  width: 100%;
  border: 1px solid var(--c-line-strong);
  border-radius: 8px;
  background: var(--c-surface);
  box-shadow: var(--lp-demo-shadow);
  z-index: 10;
}
.dsl-select.is-open .dsl-select__list { display: block; }
.dsl-select__opt { display: block; padding: 7px 10px; font-size: 13px; }
.dsl-select__opt.is-picked { background: color-mix(in srgb, var(--c-accent) 14%, transparent); }

.dsl-bullets { margin-bottom: 14px; }
.dsl-bullets li { margin-bottom: 6px; font-size: 13px; }
.dsl-toast { display: none; margin-top: 10px; }
.dsl-stage.is-reminded .dsl-toast { display: block; }
.dsl-stage.is-reminded [data-dsl-remind] { display: none; }

.dsl-paycard { margin-top: 14px; padding: 12px 14px; }
.dsl-paycard .mx-card__title { font-size: 13px; }
.dsl-paycard .mx-hint { margin-bottom: 8px; }
.dsl-paylink { overflow: hidden; }
.dsl-paylink .link {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-family: var(--font-mono);
  font-size: 11.5px;
}

@media (min-width: 576px) {
  .dsl { max-width: 1040px; margin-inline: auto; }
}

/* ── The pictures on the landing's cards (render.mjs membersViz, levelsViz) ─────────────────────────────────────
   Each is a miniature of its own feature, in the product's tokens (accent, dark and light follow). */
.lp-viz--scene { height: 8.25rem; }
.dlv { direction: ltr; color: var(--c-ink); font-family: var(--font-mono, ui-monospace, monospace); font-size: 0.75rem; display: flex; align-items: center; justify-content: center; gap: 0.7rem; position: relative; }
.dlv, .dlv * { box-sizing: border-box; }
.dlv i, .dlv u, .dlv b { font-style: normal; text-decoration: none; display: block; }

/* members as people, each paid or due */
.dlv-members { flex-direction: column; gap: 5px; width: 12rem; align-items: stretch; }
.dlv-members > span { display: flex; align-items: center; gap: 9px; padding: 5px 9px; border-radius: 9px; background: var(--c-surface); border: 1px solid var(--c-line); animation: dlv-push 5.5s infinite; }
.dlv-members > span > i { width: 17px; height: 17px; border-radius: 50%; background: var(--c-line-strong); position: relative; overflow: hidden; flex: none; }
.dlv-members > span > i::before { content: ''; position: absolute; left: 50%; top: 3px; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: var(--c-surface); }
.dlv-members > span > i::after { content: ''; position: absolute; left: 3px; right: 3px; top: 11px; height: 10px; border-radius: 50% 50% 0 0; background: var(--c-surface); }
.dlv-members > span > u { flex: 1; height: 5px; border-radius: 3px; background: var(--c-line-strong); }
.dlv-members > span:nth-child(2) > u { margin-inline-end: 22%; } .dlv-members > span:nth-child(3) > u { margin-inline-end: 38%; }
.dlv-members > span > b { width: 16px; height: 16px; border-radius: 50%; background: var(--c-accent); position: relative; flex: none; }
.dlv-members > span > b::after { content: ''; position: absolute; left: 4px; top: 4px; width: 7px; height: 4px; border: solid var(--c-accent-ink); border-width: 0 0 2px 2px; transform: rotate(-45deg); }
.dlv-members > span > b.is-due { background: transparent; border: 2px dashed var(--c-line-strong); }
.dlv-members > span > b.is-due::after { display: none; }
.dlv-members > span.is-new { border-color: var(--c-accent); animation-name: dlv-join; }
.dlv-members > span.is-new > i { background: var(--c-accent); } .dlv-members > span.is-new > u { background: var(--c-ink); }
@keyframes dlv-join { 0%, 8% { opacity: 0; transform: translateY(-100%); } 20%, 100% { opacity: 1; transform: none; } }
@keyframes dlv-push { 0%, 8% { transform: translateY(-110%); } 20%, 100% { transform: none; } }

/* levels of your own, each with its fee */
.dlv-levels { align-items: flex-end; gap: 8px; height: 5.4rem; }
.dlv-levels > span { width: 3.4rem; border-radius: 9px 9px 4px 4px; background: var(--c-surface); border: 1px solid var(--c-line-strong); display: grid; place-items: end center; padding-bottom: 7px; font-weight: 700; animation: dlv-tier 7.5s infinite; }
/* negative delays: every level is mid-loop from the first frame, and a level never shows its lit state early */
.dlv-levels > span:nth-child(1) { height: 2.5rem; } .dlv-levels > span:nth-child(2) { height: 3.7rem; animation-delay: -5s; } .dlv-levels > span:nth-child(3) { height: 4.9rem; animation-delay: -2.5s; }
@keyframes dlv-tier { 0%, 30% { background: var(--c-accent); border-color: var(--c-accent); color: var(--c-accent-ink); } 34%, 100% { background: var(--c-surface); border-color: var(--c-line-strong); color: var(--c-ink); } }
/* the member stands on whichever level is theirs now */
.dlv-levels > span { position: relative; }
.dlv-levels > span::before { content: ''; position: absolute; left: 50%; bottom: 100%; width: 15px; height: 15px; margin: 0 0 5px -7.5px; border-radius: 50%; background: var(--c-ink); opacity: 0; animation: dlv-stand 7.5s infinite; }
.dlv-levels > span:nth-child(2)::before { animation-delay: -5s; }
.dlv-levels > span:nth-child(3)::before { animation-delay: -2.5s; }
@keyframes dlv-stand { 0% { opacity: 0; transform: translateY(6px); } 3%, 30% { opacity: 1; transform: none; } 34%, 100% { opacity: 0; transform: translateY(6px); } }
.dlv-levels > i { display: none; }

/* dues requests that make themselves: the calendar turns to the 1st, each member's request appears, one e-mail to the admins */
.dlv-auto { gap: 0.6rem; }
.dlv-auto__cal { width: 3.2rem; border-radius: 8px; background: var(--c-surface); border: 1px solid var(--c-line-strong); overflow: hidden; flex: none; }
.dlv-auto__cal > i { height: 10px; background: var(--c-accent); }
.dlv-auto__cal > span { display: block; height: 2.2rem; overflow: hidden; }
.dlv-auto__cal b { height: 2.2rem; line-height: 2.2rem; text-align: center; font-size: 1.25rem; font-weight: 700; animation: dlv-turn 8s infinite; }
@keyframes dlv-turn { 0%, 14% { transform: none; } 20%, 94% { transform: translateY(-100%); } 100% { transform: none; } }
.dlv-auto__go { width: 0.9rem; height: 2px; background: var(--c-line-strong); position: relative; flex: none; }
.dlv-auto__go::after { content: ''; position: absolute; right: 0; top: -3px; width: 6px; height: 6px; border: solid var(--c-line-strong); border-width: 2px 2px 0 0; transform: rotate(45deg); }
.dlv-auto__reqs { display: grid; gap: 4px; width: 6.8rem; }
.dlv-auto__reqs > span { display: flex; align-items: center; gap: 7px; padding: 4px 8px; border-radius: 8px; background: var(--c-surface); border: 1px solid var(--c-line); opacity: 0; animation: dlv-req 8s infinite; }
.dlv-auto__reqs > span:nth-child(2) { animation-name: dlv-req-2; }
.dlv-auto__reqs > span:nth-child(3) { animation-name: dlv-req-3; }
.dlv-auto__reqs i { width: 14px; height: 14px; border-radius: 50%; background: var(--c-line-strong); flex: none; }
.dlv-auto__reqs u { flex: 1; height: 5px; border-radius: 3px; background: var(--c-line-strong); }
.dlv-auto__reqs b { width: 14px; height: 14px; border-radius: 50%; border: 2px dashed var(--c-accent); flex: none; }
@keyframes dlv-req { 0%, 22% { opacity: 0; transform: translateX(-10px); } 28%, 92% { opacity: 1; transform: none; } 98%, 100% { opacity: 0; } }
@keyframes dlv-req-2 { 0%, 29% { opacity: 0; transform: translateX(-10px); } 35%, 92% { opacity: 1; transform: none; } 98%, 100% { opacity: 0; } }
@keyframes dlv-req-3 { 0%, 36% { opacity: 0; transform: translateX(-10px); } 42%, 92% { opacity: 1; transform: none; } 98%, 100% { opacity: 0; } }
.dlv-auto__mail { position: relative; width: 2.7rem; height: 1.85rem; border-radius: 4px; border: 2px solid var(--c-ink); background: var(--c-surface); flex: none; animation: dlv-mail 8s infinite; }
.dlv-auto__mail::before { content: ''; position: absolute; inset-inline: 7px; top: 1px; height: 13px; border: solid var(--c-ink); border-width: 0 0 2px 2px; transform: rotate(-45deg) scale(0.74); transform-origin: top; }
.dlv-auto__mail > em { position: absolute; top: -9px; right: -10px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: var(--c-accent); color: var(--c-accent-ink); font-style: normal; font-weight: 700; font-size: 0.6875rem; line-height: 18px; text-align: center; opacity: 0; animation: dlv-count 8s infinite; }
@keyframes dlv-mail { 0%, 48% { transform: none; } 52% { transform: rotate(-8deg); } 56% { transform: rotate(6deg); } 60%, 100% { transform: none; } }
@keyframes dlv-count { 0%, 50% { opacity: 0; transform: scale(0.5); } 56%, 92% { opacity: 1; transform: none; } 98%, 100% { opacity: 0; } }
