/* Welcome - see core/welcome.js. Every colour comes from the app's own tokens, so the
   same file is IceTime-blue on IceTime and YogaTime-plum on YogaTime, light or dark.
   The fallbacks only matter on a page that defines no tokens at all. */

.welcome {
  width: min(30rem, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  padding: 0;
  border: 1px solid var(--line, #dde3ee);
  border-radius: var(--radius, 14px);
  background: var(--surface, #fff);
  color: var(--ink, #16203a);
  box-shadow: var(--shadow, 0 8px 24px rgba(16, 26, 51, .12));
  overflow: auto;
  overscroll-behavior: contain;
}
/* ::backdrop inherits nothing from the page in some browsers, so no tokens here. */
.welcome::backdrop { background: rgba(8, 14, 30, .55); }
html.welcome-open { overflow: hidden; }

.welcome-body { padding: 28px 24px 22px; }

.welcome-hello {
  margin: 0;
  color: var(--ink-2, #5b6784);
  font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
}
.welcome-name {
  margin: 2px 0 10px;
  font-size: clamp(1.9rem, 8vw, 2.3rem); letter-spacing: -.02em; line-height: 1.1;
}
.welcome-name span { color: var(--accent, #2f5bd6); }
.welcome-lede { margin: 0 0 20px; color: var(--ink-2, #5b6784); }

.welcome-points {
  display: grid; gap: 14px;
  margin: 0 0 22px; padding: 0;
  list-style: none; counter-reset: welcome;
}
.welcome-points li {
  display: grid; grid-template-columns: 26px 1fr; column-gap: 12px;
  counter-increment: welcome;
}
.welcome-points li::before {
  content: counter(welcome);
  grid-row: span 2;
  display: grid; place-items: center;
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--accent, #2f5bd6); color: var(--accent-ink, #fff);
  font-size: .8rem; font-weight: 700;
}
.welcome-points strong { font-size: .98rem; }
.welcome-points span { color: var(--ink-2, #5b6784); font-size: .92rem; }

/* The road: three stops on a line, the ones behind filled, the current one ringed. */
.welcome-road {
  margin: 0 0 22px; padding: 16px 16px 14px;
  border: 1px solid var(--line, #dde3ee);
  border-radius: 12px;
  background: var(--surface-2, transparent);
}
.welcome-road h3 {
  margin: 0 0 14px;
  color: var(--ink-2, #5b6784);
  font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
}
.welcome-road ol {
  display: grid; grid-template-columns: repeat(3, 1fr);
  margin: 0; padding: 0; list-style: none;
}
.welcome-road li {
  position: relative;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  text-align: center;
}
/* The line between stops, drawn from each stop back to the one before it. */
.welcome-road li + li::before {
  content: "";
  position: absolute; top: 6px; right: 50%; width: 100%; height: 2px;
  background: var(--line, #dde3ee);
}
.welcome-road li.is-done + li::before { background: var(--accent, #2f5bd6); }
.welcome-dot {
  position: relative; z-index: 1;
  width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid var(--line, #dde3ee);
  background: var(--surface, #fff);
}
.is-done .welcome-dot { border-color: var(--accent, #2f5bd6); background: var(--accent, #2f5bd6); }
.is-now .welcome-dot {
  border-color: var(--accent, #2f5bd6);
  box-shadow: 0 0 0 4px var(--ring, rgba(47, 91, 214, .28));
}
.welcome-step { font-size: .86rem; line-height: 1.3; }
.is-next .welcome-step { color: var(--ink-2, #5b6784); }
.is-now .welcome-step { font-weight: 600; }
.welcome-tag {
  padding: 1px 8px; border-radius: 999px;
  background: var(--accent, #2f5bd6); color: var(--accent-ink, #fff);
  font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
}

.welcome-notice {
  margin: 0 0 12px; font-size: .84rem; line-height: 1.45;
  color: var(--ink-2, #5b6784);
}
.welcome-notice a { color: var(--accent, #2f5bd6); }

.welcome-go {
  display: block; width: 100%;
  padding: 12px 16px;
  border: 0; border-radius: 10px;
  background: var(--accent, #2f5bd6); color: var(--accent-ink, #fff);
  font: inherit; font-weight: 600;
  cursor: pointer;
}
.welcome-go:focus-visible { outline: 3px solid var(--ring, rgba(47, 91, 214, .28)); outline-offset: 2px; }

@media (prefers-reduced-motion: no-preference) {
  .welcome[open] { animation: welcome-in .22s ease-out; }
  .welcome[open]::backdrop { animation: welcome-fade .22s ease-out; }
}
@keyframes welcome-in { from { opacity: 0; transform: translateY(12px) scale(.98); } }
@keyframes welcome-fade { from { opacity: 0; } }
