/* 3.0's launch (index.html #launch; app.js launch, launch.js): the update said big, once. The dialog covers the whole
   screen, so the confetti (launch.js's canvas, over everything and never in the way of a tap) has all of it; in the
   middle, a Versal card: square corners, flat fills, a ruled edge and the stripe's orange and blue along its top, the
   big number split into the tutor's orange and the student's blue as the Thinking line is. Its parts arrive one after
   another only when motion is fine: with reduced motion they're simply there, and launch.js draws no confetti. */
.launch { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0;
  padding: 24px 16px; border: 0; background: transparent; color: var(--ws-text); overflow: auto;
  overscroll-behavior: contain; }
.launch[open] { display: grid; }  /* only open: a closed dialog stays out of sight */
.launch::backdrop { background: rgb(0 0 0 / 0.72); }
.launch-burst { position: fixed; inset: 0; z-index: 2; width: 100%; height: 100%; pointer-events: none; }
.launch-card { position: relative; z-index: 1; width: min(560px, 100%); margin: auto; padding: 36px 32px 28px;
  border: 1px solid var(--ws-border-strong); border-radius: 0; background: var(--ws-surface); }
.launch-stripe { position: absolute; top: -1px; left: -1px; right: -1px; display: flex; height: 6px; }
.launch-stripe span { flex: 1; }
.launch-stripe span:first-child { background: var(--ws-stripe-left); }
.launch-stripe span:last-child { background: var(--ws-stripe-right); }
.launch-x { position: absolute; top: 14px; right: 14px; }
.launch-badge { margin: 0; color: var(--ws-signal-text); font-size: 13px; font-weight: 700; letter-spacing: 0.16em;
  text-transform: uppercase; }
.launch-num { margin: 6px 0 0; font-family: var(--ws-display); font-size: clamp(96px, 26vw, 168px); font-weight: 700;
  line-height: 0.88; letter-spacing: -0.06em; color: var(--ws-text);
  text-shadow: -4px 0 0 var(--ws-tutor-name), 4px 0 0 var(--ws-student-name); }
.launch-card h2 { margin: 18px 0 6px; font-size: 28px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.15;
  overflow-wrap: anywhere; }
.launch-lead { margin: 0 0 20px; color: var(--ws-muted); font-size: 16px; line-height: 1.5; }
.launch-list { display: grid; gap: 8px; margin: 0 0 24px; padding: 0; list-style: none; }
.launch-item { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border: 1px solid var(--ws-border);
  border-left: 4px solid var(--ws-stripe-left); background: var(--ws-surface-2); }
.launch-item:nth-child(even) { border-left-color: var(--ws-stripe-right); }
.launch-pic { display: inline-flex; flex: none; align-items: center; justify-content: center; width: 44px; height: 44px;
  background: var(--ws-stripe-left); color: var(--ws-on-signal); }
.launch-item:nth-child(even) .launch-pic { background: var(--ws-stripe-right); }
.launch-pic svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: square;
  stroke-linejoin: miter; }
.launch-pic .half { fill: currentColor; stroke: none; }
.launch-words { display: grid; gap: 2px; min-width: 0; }
.launch-words strong { font-size: 17px; font-weight: 700; line-height: 1.25; }
.launch-words span { color: var(--ws-muted); font-size: 15px; line-height: 1.4; }
.launch-go { min-height: 52px; font-size: 17px; font-weight: 700; }

@media (prefers-reduced-motion: no-preference) {
  .launch[open]::backdrop { animation: launch-fade 300ms ease-out both; }
  .launch[open] .launch-card { animation: launch-pop 520ms cubic-bezier(0.2, 0.8, 0.2, 1) both; }
  .launch[open] .launch-stripe { transform-origin: left; animation: launch-sweep 700ms 200ms cubic-bezier(0.7, 0, 0.2, 1) both; }
  .launch[open] .launch-num { animation: launch-split 760ms 160ms steps(5, end) both; }
  .launch[open] .launch-item { animation: launch-row 420ms cubic-bezier(0.2, 0.8, 0.2, 1) both; }
  .launch[open] .launch-item:nth-child(1) { animation-delay: 380ms; }
  .launch[open] .launch-item:nth-child(2) { animation-delay: 470ms; }
  .launch[open] .launch-item:nth-child(3) { animation-delay: 560ms; }
  .launch[open] .launch-item:nth-child(4) { animation-delay: 650ms; }
  .launch[open] .launch-item:nth-child(5) { animation-delay: 740ms; }
  .launch[open] .launch-item:nth-child(n + 6) { animation-delay: 830ms; }
}
@keyframes launch-fade { from { opacity: 0; } }
@keyframes launch-pop { from { opacity: 0; transform: scale(0.82); } 60% { opacity: 1; transform: scale(1.03); } to { transform: none; } }
@keyframes launch-sweep { from { transform: scaleX(0); } }
@keyframes launch-split {
  0% { opacity: 0; transform: translateX(-12px) skewX(-10deg);
    text-shadow: -18px 0 0 var(--ws-tutor-name), 18px 0 0 var(--ws-student-name); }
  30% { opacity: 1; transform: translateX(6px); text-shadow: 10px 0 0 var(--ws-tutor-name), -10px 0 0 var(--ws-student-name); }
  60% { transform: translateX(-3px); text-shadow: -8px 0 0 var(--ws-tutor-name), 8px 0 0 var(--ws-student-name); }
  100% { transform: none; }
}
@keyframes launch-row { from { opacity: 0; transform: translateX(-20px); } }

@media (max-width: 640px) {
  .launch { padding: 16px 12px; }
  .launch-card { padding: 28px 16px 16px; }
  .launch-x { top: 10px; right: 10px; }
  .launch-card h2 { margin-top: 14px; font-size: 22px; }
  .launch-lead { margin-bottom: 16px; font-size: 15px; }
  .launch-item { gap: 12px; padding: 10px; }
  .launch-pic { width: 40px; height: 40px; }
  .launch-words strong { font-size: 16px; }
  .launch-words span { font-size: 14px; }
}
/* A short screen (900px or less: at full size the card's five lines need about 890; a 1366x768 laptop's browser is
   about 625px tall, a phone's often less): closer together and a smaller number, so the whole card fits with no
   scrolling, and with the next block down to about 590px tall. Lower still, app.js launch opens it at its top, not
   scrolled down to Let's go. After the phone rules, so it wins on a phone too; it only ever takes space away. */
@media (max-height: 900px) {
  .launch { padding-top: 12px; padding-bottom: 12px; }
  .launch-card { padding-top: 24px; padding-bottom: 16px; }
  .launch-num { margin-top: 2px; font-size: clamp(64px, min(26vw, 16vh), 168px); }
  .launch-card h2 { margin: 10px 0 4px; }
  .launch-lead { margin-bottom: 12px; }
  .launch-list { gap: 6px; margin-bottom: 14px; }
  .launch-item { padding-top: 8px; padding-bottom: 8px; }
  .launch-pic { width: 36px; height: 36px; }
  .launch-pic svg { width: 20px; height: 20px; }
  .launch-words strong { font-size: 16px; }
  .launch-words span { font-size: 14px; }
  .launch-go { min-height: 46px; }
}
/* Shorter still (that laptop's browser), or a phone at any height (most lines take two rows there): the rows close up
   too and Let's go sits right under them, so five lines fit where four did. Spacing only: the words keep their size. */
@media (max-height: 700px), (max-width: 640px) {
  .launch-card h2 { margin: 8px 0 2px; }
  .launch-lead { margin-bottom: 10px; }
  .launch-list { gap: 4px; margin-bottom: 12px; }
  .launch-item { padding-top: 5px; padding-bottom: 5px; }
  .launch-words { gap: 0; }
  .launch-card .launch-go { margin-top: 0; }  /* app.css's .btn.wide gap: the list's own margin is enough */
}
@media (forced-colors: active) {
  .launch-burst { display: none; }
}
