/* QQTour (JS/Tour.js): the page dims, one part is lit up, and a note beside it explains it.
   Colours follow the page (html.dark for the dark look). */
:root { --qt-bg: #ffffff; --qt-ink: #1c2633; --qt-muted: #5f6b7a; --qt-brand: #0a5bd6; --qt-brand-dark: #0a3f94; --qt-line: #dfe4ea; --qt-shade: rgba(12, 24, 44, .58); }
html.dark { --qt-bg: #1b2738; --qt-ink: #e6edf7; --qt-muted: #9aabc3; --qt-brand: #4d8dff; --qt-brand-dark: #2f6fe0; --qt-line: #2f4260; --qt-shade: rgba(0, 0, 0, .68); }

/* catches every click on the page while the tour runs */
.qt-shade { background: transparent; inset: 0; position: fixed; z-index: 9000; }
.qt-shade.qt-dim { background: var(--qt-shade); }
.qt-spot {
    border-radius: 10px; box-shadow: 0 0 0 3px var(--qt-brand), 0 0 0 9999px var(--qt-shade); pointer-events: none; position: fixed; z-index: 9001;
    transition: left .25s ease, top .25s ease, width .25s ease, height .25s ease;
}
.qt-spot.qt-gone { display: none; }

.qt-pop {
    background: var(--qt-bg); border-radius: 12px; box-shadow: 0 12px 40px rgba(0, 0, 0, .3); color: var(--qt-ink); font-size: .92rem;
    line-height: 1.45; max-width: calc(100vw - 32px); padding: 14px 16px 14px; position: fixed; width: 360px; z-index: 9002;
    animation: qt-in .2s ease;
}
.qt-pop.qt-mid { left: 50%; top: 50%; transform: translate(-50%, -50%); width: 420px; animation: none; }
.qt-pop.qt-low { bottom: 16px; left: 50%; transform: translateX(-50%); animation: none; }
/* phones: room below the page, so a part near the bottom can still scroll up clear of the note */
@media (max-width: 599px) { html.qt-on body { padding-bottom: 70vh; } }
@keyframes qt-in { from { opacity: 0; transform: translateY(6px); } }

.qt-head { align-items: center; display: flex; justify-content: space-between; }
.qt-count { color: var(--qt-muted); font-size: .75rem; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.qt-x { background: none; border: 0; border-radius: 6px; color: var(--qt-muted); cursor: pointer; font-size: 1rem; line-height: 1; padding: 4px 6px; }
.qt-x:hover { background: var(--qt-line); color: var(--qt-ink); }
.qt-bar { background: var(--qt-line); border-radius: 99px; height: 3px; margin: 8px 0 12px; overflow: hidden; }
.qt-bar span { background: var(--qt-brand); display: block; height: 100%; transition: width .25s ease; }
.qt-pop h3 { color: var(--qt-ink); font-size: 1.05rem; margin: 0 0 6px; }
.qt-text p { margin: 0 0 8px; }
.qt-text p:last-child { margin-bottom: 0; }
.qt-text ul { margin: 0 0 8px; padding-left: 20px; }
.qt-text .qt-ic { display: inline-block; height: 16px; vertical-align: -3px; width: 16px; }

.qt-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 14px; }
.qt-btn {
    background: transparent; border: 1px solid var(--qt-line); border-radius: 8px; color: var(--qt-ink); cursor: pointer; font: inherit;
    font-weight: 600; padding: 7px 14px;
}
.qt-btn:hover { border-color: var(--qt-brand); color: var(--qt-brand); }
.qt-btn.primary { background: var(--qt-brand); border-color: var(--qt-brand); color: #fff; min-width: 84px; }
.qt-btn.primary:hover { background: var(--qt-brand-dark); border-color: var(--qt-brand-dark); color: #fff; }
.qt-btn:focus-visible, .qt-x:focus-visible { outline: 2px solid var(--qt-brand); outline-offset: 2px; }

/* A page's "? Show me how" button and the first-visit note offering its tour (both start hidden; the page's tour script shows them) */
.qt-help {
    align-items: center; background: var(--card); border: 1px solid var(--btn-line, var(--line)); border-radius: 999px; color: var(--brand);
    cursor: pointer; display: inline-flex; font: inherit; font-size: .9rem; font-weight: 600; gap: 7px; padding: 6px 14px 6px 7px;
}
.qt-help span { background: var(--brand); border-radius: 50%; color: #fff; display: inline-grid; font-size: .8rem; height: 22px; place-items: center; width: 22px; }
.qt-help:hover { border-color: var(--brand); }
.qt-help[hidden], .qt-hello[hidden], .card.qt-hello[hidden] { display: none !important; }
/* The first-visit note: a bold blue band so it isn't mistaken for the page's own content */
.card.qt-hello {
    align-items: center; background: linear-gradient(120deg, #173a6e 0%, #0a5bd6 70%, #2f7ef0 100%); border: 0; border-radius: 14px;
    box-shadow: 0 8px 24px rgba(10, 60, 140, .28); color: #fff; display: flex; flex-wrap: wrap; gap: 12px 18px;
    margin-bottom: 16px !important; overflow: hidden; padding: 18px 22px; position: relative; animation: qt-hello-in .45s ease;
}
.card.qt-hello::before {   /* a big "?" in a circle */
    align-items: center; background: rgba(255, 255, 255, .18); border: 2px solid rgba(255, 255, 255, .55); border-radius: 50%; content: "?";
    display: flex; flex: none; font-size: 1.5rem; font-weight: 800; height: 48px; justify-content: center; width: 48px;
}
.card.qt-hello::after {   /* a soft glow on the right */
    background: radial-gradient(circle, rgba(255, 255, 255, .22), transparent 70%); content: ""; height: 260px; pointer-events: none;
    position: absolute; right: -60px; top: -90px; width: 260px;
}
.qt-hello p { color: #fff; flex: 1 1 260px; font-size: 1.02rem; line-height: 1.45; margin: 0; }
.qt-hello p b { color: #fff; display: block; font-size: 1.15rem; margin-bottom: 2px; }
.qt-hello div { display: flex; flex-wrap: wrap; gap: 10px; position: relative; z-index: 1; }
/* its buttons: white for the tour, an outline for No thanks (whichever button classes the page uses) */
.qt-hello button { border-radius: 10px; cursor: pointer; font: inherit; font-size: .95rem; font-weight: 700; min-height: 42px; padding: 9px 18px; }
.qt-hello button:first-child { background: #fff; border: 2px solid #fff; color: #0a4fb8; box-shadow: 0 3px 10px rgba(0, 0, 0, .18); }
.qt-hello button:first-child:hover { background: #eaf2ff; border-color: #eaf2ff; color: #083f93; }
.qt-hello button:last-child { background: transparent; border: 2px solid rgba(255, 255, 255, .6); color: #fff; font-weight: 600; }
.qt-hello button:last-child:hover { background: rgba(255, 255, 255, .12); border-color: #fff; color: #fff; }
.qt-hello button:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
@keyframes qt-hello-in { from { opacity: 0; transform: translateY(-8px); } }
@media (max-width: 560px) {
    .card.qt-hello { padding: 16px; }
    .card.qt-hello::before { height: 40px; width: 40px; font-size: 1.25rem; }
    .qt-hello div, .qt-hello button { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
    .qt-spot, .qt-bar span { transition: none; }
    .qt-pop, .card.qt-hello { animation: none; }
}
