/* The guide: a ring over the control and a line along the bottom. Both
   sit in this document so the app cannot clip them, and neither takes
   pointer events, so ignoring the tour costs nothing. */
.tg-ring {
    position: fixed;
    border: 2px solid var(--accent);
    border-radius: 8px;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.22);
    pointer-events: none;
    z-index: 200;
    transition: left .18s, top .18s, width .18s, height .18s;
}
.tg-bar {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    min-height: 44px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    background: var(--bg-secondary);
    border-top: 2px solid var(--accent);
    font-size: 0.875rem;
    color: var(--text-primary);
    z-index: 201;
}
.tg-count {
    flex-shrink: 0;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    text-transform: uppercase;
}
.tg-text { flex: 1; line-height: 1.45; }
.tg-bar button {
    flex-shrink: 0;
    background: none;
    border: 1px solid var(--border);
    color: var(--text-secondary);
    border-radius: var(--radius);
    padding: 0.3rem 0.7rem;
    font-size: 0.8125rem;
    cursor: pointer;
}
.tg-bar button:hover { border-color: var(--accent); color: var(--accent); }
.tg-bar.tg-hit { border-top-color: var(--success); }
.tg-bar.tg-hit .tg-text::after { content: ' ✓'; color: var(--success); }
.tg-bar.tg-outro { border-top-color: var(--success); }
/* Two rows on a phone, not three: the count and both buttons share the
   top row, the instruction gets the one below. try-guide.js gives the
   frame back whatever height this ends up being. */
@media (max-width: 700px) {
    .tg-bar { flex-wrap: wrap; gap: 0.35rem 0.5rem; padding: 0.5rem 0.8rem; }
    .tg-count { order: 1; }
    .tg-bar button { order: 2; }
    .tg-bar .tg-next { margin-left: auto; }
    .tg-text { flex: 1 1 100%; order: 3; }
}

/* A goal step shows the number it is waiting on, so a swap that moved the
   total the wrong way is visible without hunting for the panel. */
.tg-live {
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
    font-weight: 700;
    color: var(--accent);
}
.tg-live:empty { display: none; }
@media (max-width: 700px) {
    .tg-live { order: 1; }
}
