/* ============ First-run tour ============ */
.modal.tour-modal { width: min(560px, calc(100vw - 32px)); padding: 0; overflow: hidden; }
.tour-stage {
  aspect-ratio: 2 / 1; position: relative;
  background-color: var(--bg);
  background-image: radial-gradient(circle, var(--dot) 1.1px, transparent 1.4px);
  background-size: 20px 20px;
  border-bottom: 1px solid var(--border);
}
.tour-stage svg { display: block; width: 100%; height: 100%; }
.tour-stage svg * { transform-box: fill-box; transform-origin: center; }

/* shared scene pieces */
.t-edge { fill: none; stroke-width: 2.4; stroke-linecap: round; opacity: .6; }
.t-label { fill: var(--text-3); opacity: .55; }
.t-label.strong { fill: var(--text); opacity: .7; }
.t-card { fill: var(--surface); stroke: var(--border-strong); stroke-width: 1; filter: drop-shadow(0 8px 18px rgba(16, 18, 27, .12)); }
.t-cursor path { fill: var(--text); stroke: var(--surface); stroke-width: 1.4; stroke-linejoin: round; }
.t-press { transform-origin: 0 0 !important; }
.t-key rect { fill: var(--surface); stroke: var(--border-strong); }
.t-key text { font: 600 12px/1 "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif; text-anchor: middle; fill: var(--text-2); }
.t-halo { fill: none; stroke-width: 2; animation: tHalo 2.6s ease-out infinite; }
@keyframes tHalo { from { opacity: .5; transform: scale(1); } to { opacity: 0; transform: scale(1.7); } }

/* welcome: branches grow out of the root */
.tour-stage .pop { animation: tPop var(--T) var(--d) infinite both; }
.tour-stage .draw { stroke-dasharray: 1; animation: tDraw var(--T) var(--d) infinite both; }
@keyframes tPop {
  0% { opacity: 0; transform: scale(0); }
  9% { opacity: 1; transform: scale(1.14); }
  14%, 84% { opacity: 1; transform: scale(1); }
  92%, 100% { opacity: 0; transform: scale(.7); }
}
@keyframes tDraw {
  0% { stroke-dashoffset: 1; opacity: .6; }
  12%, 84% { stroke-dashoffset: 0; opacity: .6; }
  92%, 100% { stroke-dashoffset: 0; opacity: 0; }
}

/* create */
.c-gline { stroke-width: 1.6; stroke-dasharray: 4 5; opacity: .6; }
.c-ghost circle { fill: none; stroke-width: 2; stroke-dasharray: 4 4; }
.c-ghost path { stroke-width: 2; stroke-linecap: round; }
.c-edge { stroke-dasharray: 1; }
.c-ripple { fill: none; stroke-width: 2; }

/* panel */
.p-ring { fill: none; stroke-width: 2.5; }
.p-pick { fill: none; stroke: var(--text); stroke-width: 1.8; }
.p-date text { font: 600 11.5px/1 "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif; }
.p-box { stroke: var(--border-strong); stroke-width: 1.5; fill: transparent; }
.p-tick { fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1; }

/* relink */
.r-h { fill: var(--surface); stroke: var(--accent); stroke-width: 2.2; }
.r-target { fill: none; stroke-width: 2.5; }

/* gantt */
.g-we { fill: var(--hover); }
.g-day { font: 600 9.5px/1 "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif; text-anchor: middle; fill: var(--text-3); }
.g-sep { stroke: var(--border); }
.g-today { stroke-width: 2; opacity: .8; }
.g-tip rect { fill: var(--tip-bg); }
.g-tip text { font: 600 11.5px/1 "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif; text-anchor: middle; fill: var(--tip-fg); }

/* text and controls */
.tour-body { padding: 18px 24px 4px; min-height: 148px; overflow: hidden; }
.tour-text { animation: tourText .4s var(--ease); }
@keyframes tourText { from { opacity: 0; transform: translateX(calc(var(--dir) * 18px)); } }
.tour-count { font-size: 11.5px; font-weight: 650; letter-spacing: .05em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.tour-modal h3 { margin: 0 0 6px; font-size: 19px; }
.tour-modal p { font-size: 14px; }
.tour-keys { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 12px; font-size: 12.5px; color: var(--text-2); }
.tour-foot { display: flex; align-items: center; gap: 6px; padding: 10px 16px 16px 24px; }
.tour-dots { display: flex; gap: 6px; margin-right: auto; }
.tour-dots button { width: 7px; height: 7px; border-radius: 4px; background: var(--border-strong); transition: width .35s var(--spring), background-color .2s; }
.tour-dots button.on { width: 20px; background: var(--accent); }
.tour-skip { color: var(--text-3); }
.tour-next { min-width: 92px; }
@media (max-width: 480px) { .tour-skip { display: none; } }
