/* Speaking page, invite: 100x pass (2026-09-28). The invitation writes itself as the organiser fills
   the form: a white card lying on the podium photo reads back the request as one sentence, each blank
   filling with a lightbox highlight, and the field in focus lights its blank. Above the form, the kinds
   of event I do, each with its count from my CV, pick one and it lands in the form; typing a city
   checks it against the lectures map. Loaded after the page's inline <style>; tokens from site.css. */

.inv {
  --settle: cubic-bezier(0.32, 0.72, 0, 1);
  --travel: cubic-bezier(0.28, 0.11, 0.32, 1);
}
.inv__see { margin-top: 1.4rem; }

/* Left column: stays in view on tall screens so the card can be read while the form is filled */
@media (min-width: 961px) and (min-height: 780px) {
  .inv__side { position: sticky; top: calc(var(--nav-h) + 2.5rem); }
}
.inv__fig { position: relative; width: min(100%, 470px); }
.inv__fig .photo { width: min(100%, 300px); }
.inv__fig figcaption { width: min(100%, 300px); }

/* The card: docked on the photo on wide screens, above the send button on narrow ones */
.inv__dock[data-inv-dock="side"] { position: absolute; left: 32%; right: 0; bottom: 3.4rem; }
.inv__dock[data-inv-dock="foot"]:empty { display: none; }
.inv__ticket {
  padding: 1.05rem 1.25rem 1rem; background: var(--paper); border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 1px 2px rgba(10, 13, 18, 0.06), 0 16px 40px rgba(10, 13, 18, 0.13);
  transition: transform 0.6s var(--settle), box-shadow 0.6s var(--settle);
}
.inv__ticket[hidden] { display: none; }
.inv__ticket.is-ready { transform: translateY(-6px); box-shadow: 0 2px 4px rgba(10, 13, 18, 0.06), 0 26px 56px rgba(10, 13, 18, 0.16); }
.inv__org { font-family: var(--display); font-weight: 600; font-size: 1.3rem; line-height: 1.2; color: var(--ink); overflow-wrap: anywhere; }
.inv__line { margin-top: 0.35rem; font-family: var(--display); font-weight: 500; font-size: 1.04rem; line-height: 1.55; color: var(--ink-2); overflow-wrap: anywhere; }
.inv__from { margin-top: 0.7rem; padding-top: 0.6rem; border-top: 1px solid var(--line); font-family: var(--label); font-weight: 600; font-size: 0.9rem; color: var(--muted); }
.inv__from .inv__slot.is-set { color: var(--ink); }

/* A blank: dotted while empty, a lightbox highlight draws under it once filled */
.inv__slot {
  cursor: pointer; border-radius: 3px;
  background-image: linear-gradient(var(--lightbox), var(--lightbox)); background-repeat: no-repeat;
  background-position: 0 92%; background-size: 0% 0.42em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
  transition: background-size 0.55s var(--travel), background-color 0.3s var(--travel), color 0.3s var(--travel), box-shadow 0.3s var(--travel);
}
.inv__slot.is-set { background-size: 100% 0.42em; color: var(--ink); }
.inv__slot.is-empty { color: var(--muted); text-decoration: underline dotted var(--line-2); text-decoration-thickness: 2px; text-underline-offset: 0.24em; }
.inv__slot.is-focus { background-color: var(--accent-tint); box-shadow: 0 0 0 3px var(--accent-tint); }
.inv__slot.is-flip { animation: inv-sharpen 0.45s var(--travel); }
.inv__ticket.is-tried .inv__slot.is-empty[data-req] { color: var(--danger); text-decoration-color: var(--danger); }
@keyframes inv-sharpen { from { opacity: 0; filter: blur(4px); } }

/* The panel: one white console, the event picker on top, the form below */
.inv__panel {
  padding: clamp(1.3rem, 3vw, 2.2rem); background: var(--paper); border: 1px solid var(--line);
  border-radius: 18px; box-shadow: var(--shadow-2);
}
.inv__form.form { margin-top: 1.7rem; padding: 1.7rem 0 0; background: none; box-shadow: none; border-radius: 0; border-top: 1px solid var(--line); }
.inv__kinds, .inv__aud { margin: 0; padding: 0; border: 0; min-width: 0; }
.inv__q { padding: 0; font-family: var(--display); font-weight: 600; font-size: clamp(1.25rem, 1.7vw, 1.45rem); line-height: 1.25; color: var(--ink); }
.inv__lg { padding: 0; margin-bottom: 0.35rem; font-family: var(--label); font-weight: 600; font-size: 0.92rem; color: var(--ink); }

/* Segmented choices: a white plate glides to the chosen one (placed by JS in x and y) */
.inv__seg { position: relative; isolation: isolate; display: grid; gap: 3px; padding: 4px; background: var(--mist); border-radius: 18px; }
.inv__seg--kind { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 0.9rem; }
.inv__seg--aud { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.inv__plate {
  position: absolute; left: 0; top: 0; z-index: -1; border-radius: 14px; background: var(--paper); opacity: 0;
  box-shadow: 0 1px 2px rgba(10, 13, 18, 0.08), 0 6px 18px rgba(10, 13, 18, 0.08);
  transition: transform 0.5s var(--settle), width 0.5s var(--settle), height 0.5s var(--settle), opacity 0.3s var(--travel);
}
.inv__seg.is-still .inv__plate { transition: opacity 0.3s var(--travel); }
.inv .inv__opt {
  position: relative; display: flex; flex-direction: column; justify-content: center; gap: 0.3rem;
  min-height: 46px; padding: 0.85rem 0.95rem; border-radius: 14px; cursor: pointer;
  font-family: var(--label); font-weight: 600; font-size: 0.95rem; color: var(--muted);
  transition: background-color 0.3s var(--travel), transform 0.35s var(--settle);
}
.inv__radio { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.inv .inv__opt:hover:not(.is-on) { background-color: rgba(255, 255, 255, 0.6); }
.inv .inv__opt:active { transform: scale(0.97); }
.inv .inv__opt:has(.inv__radio:focus-visible) { outline: 2px solid var(--accent); outline-offset: 1px; }
.inv__seg:not(.is-live) .inv__opt:has(.inv__radio:checked) { background: var(--paper); }
.inv__n { font-family: var(--label); font-weight: 700; font-size: clamp(1.75rem, 2.5vw, 2.3rem); line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; transition: color 0.3s var(--travel), transform 0.5s var(--settle); transform-origin: 0 100%; }
.inv .inv__opt .inv__k { font-family: var(--label); font-weight: 600; font-size: 0.95rem; line-height: 1.25; color: var(--muted); transition: color 0.3s var(--travel); }
.inv .inv__opt:hover .inv__k, .inv .inv__opt.is-on .inv__k { color: var(--ink); }
.inv__opt.is-on .inv__n { color: var(--accent); }
.inv__kind:hover .inv__n, .inv__kind.is-on .inv__n { transform: scale(1.06); }
.inv__seg--aud .inv__opt { padding: 0.7rem 0.95rem; }
.inv__sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* One line under the picker: how it was counted at rest, the latest example on point or pick */
.inv__ex { margin-top: 0.75rem; min-height: 1.5em; font-size: 0.9rem; line-height: 1.5; color: var(--muted); }
.inv__ex-in { display: inline-block; }
.inv__ex-in.is-swap { animation: inv-rise 0.45s var(--travel); }
.inv__ex b { font-weight: 600; color: var(--ink-2); }
@keyframes inv-rise { from { opacity: 0; transform: translateY(5px); filter: blur(3px); } }

/* Fields: labels and wells sit at the top of their cell, so a hint under Where never stretches Dates */
.inv .field { align-content: start; }

/* Fields: a mist well that turns white and ringed on focus, as on the Videos page */
.inv .field input, .inv .field textarea {
  background: var(--mist); border-color: transparent; border-radius: 12px;
  transition: background-color 0.3s var(--travel), border-color 0.2s, box-shadow 0.3s var(--travel);
}
.inv .field input:hover, .inv .field textarea:hover { border-color: var(--line-2); }
.inv .field input:focus, .inv .field textarea:focus { background: var(--paper); }
.inv .field textarea { min-height: 7.5rem; max-height: 22rem; }
.inv .field input.is-dropped { animation: inv-drop 0.9s var(--travel); }
@keyframes inv-drop { from { background-color: var(--accent-tint); box-shadow: 0 0 0 3px var(--accent-glow); } }

/* A check draws beside a required label once its answer is valid */
.inv__ok { display: inline-block; width: 14px; height: 14px; margin-left: 0.35rem; vertical-align: -1px; color: var(--accent); }
.inv__ok path { stroke-dasharray: 20; stroke-dashoffset: 20; transition: stroke-dashoffset 0.45s var(--travel); }
.field.is-ok .inv__ok path { stroke-dashoffset: 0; }

/* Where: what the lectures map knows about the place typed */
.inv__hint { font-size: 0.88rem; line-height: 1.45; color: var(--ink-2); }
.inv__hint:empty { display: none; }
.inv__hint.is-swap { animation: inv-rise 0.45s var(--travel); }
.inv__hint button {
  padding: 0; border: 0; background: none; font: inherit; font-weight: 600; color: var(--accent); cursor: pointer;
  text-decoration: underline; text-decoration-color: var(--accent-glow); text-decoration-thickness: 2px; text-underline-offset: 0.2em;
  transition: text-decoration-color 0.3s var(--travel);
}
.inv__hint button:hover { text-decoration-color: var(--accent); }

.inv__togo { font-family: var(--label); font-weight: 600; font-size: 0.92rem; color: var(--muted); transition: color 0.3s var(--travel); }
.inv__togo.is-ready { color: var(--accent); }

@media (max-width: 960px) {
  .inv__ticket { box-shadow: none; background: var(--mist); border-color: transparent; }
  .inv__ticket.is-ready { transform: none; box-shadow: none; }
}
@media (max-width: 600px) {
  .inv__seg--kind { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .inv__ex { min-height: 3em; }
  .inv .inv__opt { padding: 0.75rem 0.8rem; }
}
@media (prefers-reduced-motion: reduce) {
  .inv *, .inv *::before, .inv *::after { transition: none !important; animation: none !important; }
}
