/* Keyboard shortcuts (help/shortcuts/). shortcuts.js draws the keys for the visitor's
   computer, slides the Mac / Windows / Chromebook switch, and plays the demo: the
   three moves on a real video, the keys pressing in time. (Numbered steps: help.css.) */

.ks { width: min(980px, calc(100% - 32px)); margin: 0 auto 120px; }

/* ---------- the top ---------- */
.ks-head { padding: clamp(56px, 8vw, 96px) 0 0; text-align: center; }
.ks-title .l1 { font-size: clamp(46px, 7vw, 92px); }
.ks-title .l2 { font-size: clamp(36px, 5.6vw, 72px); }
.ks-lede { max-width: 520px; margin: 22px auto 0; font-size: clamp(17px, 1.8vw, 19px); line-height: 1.55; color: #3E3858; }
.ks-phone { margin: 14px 0 0; font-size: 14px; color: var(--muted); }

/* Mac / Windows / Chromebook: the same sliding range as Pricing's switch */
.ks-os { position: relative; display: flex; width: max-content; max-width: 100%; margin: 32px auto 0; padding: 5px; border: 1px solid var(--line); border-radius: 999px; background: #fff; }
.ks-os button { position: relative; z-index: 1; padding: 10px 20px; border: 0; border-radius: 999px; background: none; color: #3E3858; font: 600 15px/1.2 var(--body); cursor: pointer; transition: color 0.25s; }
.ks-os button[aria-checked="true"] { color: #fff; }
.ks-os button:focus-visible { outline: 2px solid var(--violet); outline-offset: 2px; }
.ks-os-range { position: absolute; top: 5px; bottom: 5px; left: 0; width: var(--w, 0); transform: translateX(var(--x, 0)); border-radius: 999px; background: var(--violet); box-shadow: 0 8px 20px -8px rgba(91, 43, 224, 0.7); }
.ks-ready .ks-os-range { transition: transform 0.45s cubic-bezier(0.34, 1.3, 0.64, 1), width 0.45s cubic-bezier(0.34, 1.3, 0.64, 1); }

/* ---------- a key ---------- */
.k {
  display: inline-grid;
  place-items: center;
  min-width: 46px;
  height: 46px;
  padding: 0 12px;
  border: 1px solid #D9D0F3;
  border-radius: 11px;
  background: linear-gradient(180deg, #fff, #F6F2FF);
  box-shadow: 0 3px 0 #D9D0F3, 0 6px 14px -8px rgba(27, 21, 48, 0.35);
  color: var(--ink);
  font: 600 18px/1 var(--body);
  transition: transform 0.12s, box-shadow 0.12s, background 0.12s, color 0.12s;
}
.k + .k { margin-left: 8px; }
.k.mod, .k.wide { min-width: 64px; font-size: 15px; }
.ks[data-os="mac"] .k.mod { font-size: 20px; } /* ⌥ reads better a little bigger */
.k.down { transform: translateY(3px); box-shadow: 0 0 0 #D9D0F3, 0 2px 6px -4px rgba(27, 21, 48, 0.35); background: var(--violet); color: #fff; border-color: var(--violet); }

/* ---------- the demo ---------- */
.ks-demo { margin-top: 56px; }
.ks-screen { position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: 24px; background: var(--ink); box-shadow: 0 40px 80px -40px rgba(27, 21, 48, 0.6); }
.ks-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.9; }
.ks-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.ks-flash.on { animation: ks-flash 0.5s ease-out; }
@keyframes ks-flash { 15% { opacity: 0.85; } }
.ks-toast { position: absolute; top: 18px; left: 50%; margin: 0; padding: 9px 14px; border-radius: 10px; background: rgba(20, 20, 24, 0.92); color: #fff; font-size: 14px; font-weight: 500; white-space: nowrap; opacity: 0; transform: translate(-50%, -8px); transition: opacity 0.25s, transform 0.25s; }
.ks-toast.on { opacity: 1; transform: translate(-50%, 0); }
/* Vclip's own panel, as it looks in the extension */
.ks-panel { position: absolute; left: 50%; bottom: 18px; width: min(560px, calc(100% - 36px)); transform: translateX(-50%); padding: 14px 18px 12px; border: 1px solid #2e2e38; border-radius: 14px; background: rgba(20, 20, 24, 0.94); box-shadow: 0 12px 40px rgba(0, 0, 0, 0.45); }
.ks-track { position: relative; height: 6px; margin: 8px 5px 12px; border-radius: 3px; background: rgba(255, 255, 255, 0.16); }
.ks-range { position: absolute; top: -3px; bottom: -3px; left: var(--a, 0); width: calc(var(--b, 0) - var(--a, 0)); overflow: hidden; background: rgba(139, 92, 246, 0.3); border-top: 2px solid #8B5CF6; border-bottom: 2px solid #8B5CF6; opacity: 0; transition: opacity 0.2s; }
.ks-range b { position: absolute; inset: 0; width: var(--fill, 0%); background: rgba(168, 139, 255, 0.6); }
.ks-h { position: absolute; top: -7px; width: 10px; height: 20px; margin-left: -5px; border-radius: 4px; background: #fff; border: 2px solid #8B5CF6; opacity: 0; transform: scale(0.4); transition: opacity 0.2s, transform 0.3s cubic-bezier(0.34, 1.6, 0.64, 1); }
.ks-h1 { left: var(--a, 0); }
.ks-h2 { left: var(--b, 0); }
.ks-now { position: absolute; top: -4px; left: var(--now, 0); width: 2px; height: 14px; margin-left: -1px; border-radius: 1px; background: #fff; }
.ks-panel.has-a .ks-h1, .ks-panel.has-b .ks-h2 { opacity: 1; transform: none; }
.ks-panel.has-b .ks-range { opacity: 1; }
.ks-status { margin: 0; color: #f4f4f7; font-size: 14px; font-weight: 500; font-variant-numeric: tabular-nums; }

/* the keys pressing in time, under the screen */
.ks-press { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 22px; }
.ks-combo { display: grid; grid-template-columns: auto auto; justify-content: center; align-items: center; row-gap: 10px; }
.ks-combo small { grid-column: 1 / -1; text-align: center; font-size: 13px; font-weight: 600; color: var(--muted); transition: color 0.15s; }
.ks-combo.on small { color: var(--violet); }

/* ---------- the lists ---------- */
.ks-list, .ks-change { margin-top: 88px; }
.ks-list h2, .ks-change h2 { margin: 0; font: 700 clamp(28px, 3vw, 36px)/1.15 var(--display); }
.ks-sub { margin: 8px 0 0; color: var(--muted); }
.ks-list dl { margin: 22px 0 0; border-top: 1px solid var(--line); }
.ks-list dl > div { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 24px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.ks-list dt { display: flex; align-items: center; }
.ks-list dd { margin: 0; font-size: 17px; line-height: 1.55; color: #3E3858; }
.ks-list dd b { color: var(--ink); }

.ks-change { max-width: 720px; }
.ks-change p { margin: 14px 0 0; color: #3E3858; }
.ks-change .hc-steps { margin-top: 20px; color: #3E3858; }
.ks-change a { color: var(--violet); text-underline-offset: 3px; }
.ks-change code { padding: 2px 7px; border-radius: 6px; background: var(--lilac); color: var(--violet-hover); font: 600 15px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; }
.ks-copy { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; padding: 10px 10px 10px 18px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.ks-copy code { padding: 0; background: none; font-size: 16px; overflow-wrap: anywhere; }
.ks-note { font-size: 15px; }

/* ---------- less motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .k, .ks-h, .ks-range, .ks-toast, .ks-ready .ks-os-range, .ks-os button { transition: none; }
}

/* ---------- tablets and phones ---------- */
@media (max-width: 1023px) {
  .ks { margin-bottom: 96px; }
  .ks-list, .ks-change { margin-top: 72px; }
}
@media (max-width: 640px) {
  .ks-os button { padding: 10px 14px; font-size: 14px; }
  .ks-screen { border-radius: 18px; aspect-ratio: 4 / 3; }
  .ks-panel { bottom: 10px; padding: 10px 12px 9px; }
  .ks-status { font-size: 12px; }
  .ks-toast { top: 10px; font-size: 12px; }
  .ks-press { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 18px; }
  .k { min-width: 40px; height: 40px; padding: 0 10px; font-size: 16px; border-radius: 10px; }
  .k.mod, .k.wide { min-width: 54px; font-size: 14px; }
  .k + .k { margin-left: 6px; }
  .ks-list dl > div { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .ks-list dd { font-size: 16px; }
}
