/* Hero product tour. Scenes are module screens drawn at 960×544 and scaled to fit the stage. */
.hv-stage { position: relative; aspect-ratio: 960 / 544; overflow: hidden; background: #fff; }
/* The redrawn apps keep the real apps' typeface, not the site's; system UI stands in where Inter isn't loaded. */
.hv-ui {
  --font-body: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  position: absolute; left: 0; top: 0; width: 960px; height: 544px; display: flex; flex-direction: column;
  transform: scale(var(--hv-scale, 0.625)); transform-origin: 0 0;
  font: 400 14px/1.4 var(--font-body); color: #11132b; text-align: left;
}
.hv-ui p { margin: 0; }
.hv-ui b { font-weight: 600; }
.hv-ui--voice { background: #f7f4ef; }
.hv-ui--bridge, .hv-ui--camp { background: #f6f7fb; }
.hv-ui--portal { background: #fff; }
.hv-hd { height: 52px; flex: none; display: flex; align-items: center; gap: 14px; padding: 0 20px; border-bottom: 1px solid #e5e8ef; background: #fff; }
.hv-logo { font: 700 20px var(--font-display); letter-spacing: -0.02em; }
.hv-crumb { color: #6b7184; font-size: 13px; }
.hv-crumb b { color: #11132b; font-weight: 500; }
.hv-org { margin-left: auto; font-size: 13px; color: #42495a; }
.hv-ava { width: 30px; height: 30px; border-radius: 50%; background: #1877a6; color: #fff; font: 600 12px var(--font-body); display: grid; place-items: center; }
.hv-body { flex: 1; display: flex; min-height: 0; }
.hv-sb { width: 180px; flex: none; display: flex; flex-direction: column; gap: 2px; padding: 14px 10px; border-right: 1px solid #e5e8ef; background: #fff; }
.hv-grp { margin: 10px 8px 4px !important; font: 600 10px var(--font-body); letter-spacing: 0.12em; color: #6b7184; }
.hv-nv { padding: 7px 10px; border-radius: 8px; font-size: 13px; color: #2b3042; }
.hv-nv.is-on { background: #eef3fb; font-weight: 500; }
.hv-ui--voice .hv-nv.is-on { background: #ece8fb; }
.hv-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 16px; padding: 22px 26px; overflow: hidden; }
.hv-eyb { font: 600 11px var(--font-body); letter-spacing: 0.12em; color: #6b7184; }
.hv-ttl { font: 700 26px var(--font-body); letter-spacing: -0.02em; }
.hv-h3 { font: 600 16px var(--font-body); }
.hv-mut { font-size: 12px; color: #6b7184; }
.hv-card { background: #fff; border: 1px solid #e3e5ec; border-radius: 14px; }
.hv-pill { display: inline-block; padding: 2px 9px; border: 1px solid; border-radius: 999px; font-size: 11px; font-weight: 500; }
.hv-pill--ok { background: #e7f8ec; color: #15803d; border-color: #bfe9cc; }
.hv-pill--info { background: #e6f5fc; color: #0b6a94; border-color: #bfe3f4; }
.hv-pill--grey { background: #f1f2f5; color: #4a5064; border-color: #d9dce4; }
.hv-pink { color: #c52a79; }

.hv-mods { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.hv-mod { overflow: hidden; display: flex; flex-direction: column; gap: 6px; padding-bottom: 14px; }
.hv-mod > :not(.hv-mod-b) { padding: 0 12px; }
.hv-mod-b { height: 54px; margin-bottom: 6px; background: linear-gradient(120deg, var(--c), color-mix(in srgb, var(--c) 35%, #fff)); }

.hv-tbl { overflow: hidden; }
.hv-tbl-h { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; font-weight: 600; }
p.hv-tbl-h { flex-direction: row; align-items: center; gap: 8px; }
.hv-live { width: 9px; height: 9px; border-radius: 50%; background: #16a34a; animation: hv-pulse 1.2s ease-in-out infinite; }
.hv-row { display: grid; grid-template-columns: 28px 1.2fr 1.6fr 0.7fr 1.1fr; align-items: center; padding: 12px 16px; border-top: 1px solid #eceef3; font-size: 13px; }
.hv-row--4 { grid-template-columns: 1fr 1.3fr 0.8fr 1fr; }
.hv-th { border-top: 0; font: 600 11px var(--font-body); letter-spacing: 0.1em; color: #6b7184; }
.hv-chat { display: flex; flex-direction: column; gap: 8px; padding: 10px 16px 14px 60px; border-top: 1px solid #eceef3; background: #fbfaf7; }
.hv-msg { align-self: flex-start; max-width: 60%; padding: 8px 12px; border: 1px solid #e3e5ec; border-radius: 12px 12px 12px 4px; background: #fff; font-size: 13px; }
.hv-msg--ai { align-self: flex-end; border: 0; border-radius: 12px 12px 4px 12px; background: #ece8fb; color: #3b2a9e; }

.hv-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.hv-kpi { padding: 14px; }
.hv-kpi b { display: block; font: 700 26px var(--font-body); }
.hv-kpi i { display: block; height: 4px; margin-top: 8px; border-radius: 2px; background: #22c55e; }
.hv-kpi i.is-blue { background: #2aa6e0; }

.hv-camp-hd { display: flex; align-items: flex-end; }
.hv-btn-dark { margin-left: auto; padding: 9px 14px; border-radius: 8px; background: #11132b; color: #fff; font-size: 13px; font-weight: 600; }
.hv-camps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.hv-camp { display: flex; flex-direction: column; gap: 10px; padding: 16px; }
.hv-camp-t { display: flex; align-items: center; justify-content: space-between; font-size: 16px; }
.hv-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid #e3e5ec; border-radius: 10px; }
.hv-stats > div { padding: 10px; }
.hv-stats > div + div { border-left: 1px solid #e3e5ec; }
.hv-stats b { font: 600 20px var(--font-body); }
.hv-sms { align-self: flex-start; max-width: 360px; padding: 10px 14px; border-radius: 14px 14px 14px 4px; font-size: 13px; }

.hv-ui--dash { background: #0f1222; color: #fff; }
.hv-board-h { height: 44px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 22px; font-size: 13px; color: #a9afc4; }
.hv-board-h b { color: #fff; font-size: 15px; }
.hv-live-t { margin-left: auto; animation: hv-pulse 1.2s ease-in-out infinite; }
.hv-board { flex: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: auto 1fr; gap: 14px; padding: 0 22px 22px; }
.hv-tile, .hv-chart, .hv-first { border-radius: 12px; background: #181c33; padding: 14px; }
.hv-tile { border-top: 4px solid var(--c); }
.hv-tile p, .hv-chart p, .hv-first p { font-size: 12px; color: #a9afc4; }
.hv-tile b { font: 700 34px var(--font-body); }
.hv-chart { grid-column: 1 / 4; display: flex; flex-direction: column; gap: 10px; }
.hv-bars { flex: 1; display: flex; gap: 14px; }
.hv-bars > div { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px; font-size: 11px; color: #a9afc4; }
.hv-bars i { width: 100%; border-radius: 6px 6px 2px 2px; background: var(--dash); }
.hv-bars i.is-today { background: #22c55e; }
.hv-first { display: flex; flex-direction: column; gap: 8px; font-size: 12px; }

.hv-in { animation: hv-in 0.5s ease var(--d, 0s) both; }
.hv-d5 { --d: 3.6s; }
.hv-new { animation: hv-new 1.8s ease var(--d, 0.2s) both; }
.hv-grow { transform-origin: bottom; animation: hv-grow 0.9s cubic-bezier(0.2, 1.2, 0.4, 1) var(--d, 0s) both; }
@keyframes hv-in { from { opacity: 0; transform: translateY(8px); } }
@keyframes hv-new { 0% { opacity: 0; transform: translateY(-12px); background: #fff8e6; } 30% { opacity: 1; transform: none; background: #fff3d6; } 100% { background: transparent; } }
@keyframes hv-grow { from { transform: scaleY(0); } }
@keyframes hv-pulse { 50% { opacity: 0.3; } }

/* Player chrome */
.hv { margin: 8px 0 0; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.hv-win { position: relative; border-radius: 18px; overflow: hidden; background: #fff; box-shadow: 0 40px 80px -40px rgba(4, 2, 20, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.08); }
/* Under the screen, never over it; two lines reserved so the controls don't jump between chapters. */
.hv-cap { margin: 0; min-height: 2.8em; color: #e4e0ff; font-size: 16px; line-height: 1.4; font-weight: 500; }
/* The silent preview plays under a light veil with the Watch button on top; the tour lifts the veil. */
.hv[data-mode="preview"] .hv-stage::after { content: ""; position: absolute; inset: 0; background: rgba(13, 11, 39, 0.28); }
.hv[data-mode="preview"] .hv-cap { visibility: hidden; }
.hv-watch {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 12px;
  min-height: 56px; padding: 0 24px 0 10px; border: 0; border-radius: 999px; background: #fff; color: var(--ink);
  font: 600 16px var(--font-body); white-space: nowrap; cursor: pointer; box-shadow: 0 16px 40px -14px rgba(13, 11, 39, 0.7);
}
.hv-watch i { position: relative; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--primary); }
.hv-watch i::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--primary); animation: hv-ring 1.8s ease-out infinite; }
.hv-watch svg { width: 18px; height: 18px; margin-left: 3px; fill: #fff; }
.hv-watch:hover { background: var(--primary-tint); }
@keyframes hv-ring { from { transform: scale(1); opacity: 0.8; } to { transform: scale(1.8); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .hv-watch i::before { animation: none; } }

/* The tour's opening card, over the stage like the booking card. */
.hv-intro { position: absolute; inset: 0; display: grid; place-items: center; background: linear-gradient(var(--night-0), var(--dusk-1)); }
.hv-intro img { width: 34%; height: auto; animation: hv-intro-in 0.9s cubic-bezier(0.2, 1.2, 0.4, 1) 0.2s both; }
@keyframes hv-intro-in { from { opacity: 0; transform: scale(0.85); filter: drop-shadow(0 0 0 rgba(154, 156, 243, 0)); } to { filter: drop-shadow(0 0 24px rgba(154, 156, 243, 0.45)); } }
/* The control bar is shared with the module videos (module-video.css); here it fades out while the tour plays. */
.hv { --seek: #fff; }
.hv-bar { transition: opacity 0.25s ease; pointer-events: none; }
.hv-bar > * { pointer-events: auto; }
@media (hover: hover) { .hv[data-state="playing"] .hv-win:not(:hover):not(:focus-within) .hv-bar { opacity: 0; } }
@media (hover: none) { .hv[data-state="playing"]:not([data-ui]) .hv-win:not(:has(:focus-visible)) .hv-bar { opacity: 0; } }
.hv-watch { z-index: 1; }
.hv-foot { display: flex; align-items: flex-start; gap: 16px; }
.hv-foot .hv-cap { flex: 1; }
/* Once the tour is over, every module gets its own link instead of the one for the current chapter. */
.hv-mods { display: none; flex-wrap: wrap; gap: 8px; }
.hv-mods a {
  display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px; color: #fff; font: 600 14px var(--font-body); text-decoration: none;
}
.hv-mods a:hover { background: rgba(255, 255, 255, 0.1); }
.hv[data-chapter="end"] .hv-mods { display: flex; }
.hv[data-chapter="end"] .hv-go { display: none; }
.hv[data-chapter="end"] .hv-foot { flex-direction: column; gap: 10px; }
.hv-go {
  display: inline-flex; align-items: center; flex: none; min-height: 44px; padding: 0 16px; border-radius: 12px;
  font: 600 14px var(--font-body); text-decoration: none; cursor: pointer; background: #fff; color: var(--ink);
}
.hv-go:hover { background: var(--primary-tint); }

@media (max-width: 599px) {
  .hv-cap { font-size: 14px; }
  .hv-foot { flex-direction: column; gap: 4px; }
  .hv-end { gap: 10px; }
}
@media (min-width: 1100px) {
  .scene--intro .sc-grid { grid-template-columns: minmax(0, 3fr) minmax(0, 5fr); column-gap: 48px; }
  .scene--intro h1 { font-size: 50px; }
  .hv { margin: 0; }
}

/* Full screen: the native element or, on iPhone Safari, a fixed overlay. */
.hv:fullscreen, .hv--overlay {
  --hv-w: min(100%, calc((100dvh - 180px) * 960 / 544));
  position: fixed; inset: 0; z-index: 100; margin: 0; padding: 24px; justify-content: center; align-items: center;
  background: var(--night-0);
}
.hv:fullscreen > *, .hv--overlay > * { width: var(--hv-w); }
.hv:fullscreen .hv-cap, .hv--overlay .hv-cap { font-size: clamp(14px, 1.6vw, 22px); }
html.hv-lock { overflow: hidden; }

/* The booking card that closes each loop. It sits over the stage, outside its aria-hidden screen, so the link works. */
.hv-end {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  padding: 16px 16px 60px; text-align: center; background: linear-gradient(var(--dusk-2), var(--dusk-3));
}
.hv-end-h { margin: 0; max-width: 16em; color: #fff; font: 700 clamp(24px, 3.2vw, 38px)/1.08 var(--font-display); letter-spacing: -0.035em; animation: hv-in 0.5s ease 0.2s both; }
.hv-end-book {
  display: inline-flex; align-items: center; min-height: 48px; padding: 0 24px; border-radius: 14px; background: #fff; color: var(--ink);
  font: 600 16px var(--font-body); text-decoration: none; animation: hv-in 0.5s ease 0.9s both;
}
.hv-end-acts { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; }
.hv-end-book:hover { background: var(--primary-tint); }
.hv-again { min-height: 44px; padding: 0 18px; border: 1px solid rgba(255, 255, 255, 0.4); border-radius: 12px; background: transparent; color: #fff; font: 600 14px var(--font-body); cursor: pointer; animation: hv-in 0.5s ease 1.2s both; }
.hv-again:hover { background: rgba(255, 255, 255, 0.1); }

/* Phones, after the base rules so these win. The module link waits for the end card. Upright there's room under
   the video, so the caption stays there; sideways it becomes a small subtitle over the bottom of the video. */
@media (max-width: 599px), (max-height: 500px) and (pointer: coarse) {
  .hv-go { display: none; }
  .hv-cap { font-size: 14px; }
  .hv-mods a { min-height: 36px; padding: 0 12px; font-size: 13px; }
  .hv-end { gap: 10px; padding: 12px 12px 56px; }
  .hv-end-h { font-size: 20px; }
  .hv-end-book, .hv-again { min-height: 40px; padding: 0 16px; font-size: 14px; }
  .hv:fullscreen, .hv--overlay { --hv-w: min(100%, calc((100dvh - 92px) * 960 / 544)); padding: 12px; overflow: auto; }
}
@media (max-height: 500px) and (pointer: coarse) {
  .hv { display: grid; grid-template-columns: minmax(0, 1fr); }
  .hv-foot { display: contents; }
  .hv-win { grid-row: 2; grid-column: 1; }
  .hv-cap {
    grid-row: 2; grid-column: 1; align-self: end; justify-self: center; z-index: 2; min-height: 0; max-width: calc(100% - 40px);
    margin: 0 0 8px; padding: 2px 8px; border-radius: 6px; background: rgba(13, 11, 39, 0.72); font-size: 12px; line-height: 1.3;
    text-align: center; pointer-events: none; transition: margin 0.25s ease;
  }
  .hv-cap:empty { display: none; }
  .hv[data-ui] .hv-cap, .hv:not([data-state="playing"]) .hv-cap { margin-bottom: 54px; }
  .hv[data-chapter="end"] .hv-cap { grid-row: 3; justify-self: start; max-width: none; margin: 0; padding: 0; background: none; font-size: 14px; text-align: left; }
  .hv-mods { grid-row: 4; }
  .hv:fullscreen, .hv--overlay { grid-template-columns: var(--hv-w); align-content: center; }
  /* No room under the video in full screen, so the end card carries the module links and its caption steps aside. */
  .hv:fullscreen[data-chapter="end"] .hv-cap, .hv--overlay[data-chapter="end"] .hv-cap { display: none; }
  .hv:fullscreen .hv-mods, .hv--overlay .hv-mods {
    grid-row: 2; grid-column: 1; align-self: end; justify-self: center; justify-content: center; z-index: 3; gap: 6px; margin-bottom: 52px; padding: 0 12px;
  }
  .hv:fullscreen .hv-mods a, .hv--overlay .hv-mods a { min-height: 32px; padding: 0 10px; font-size: 12px; }
  .hv:fullscreen .hv-end, .hv--overlay .hv-end { padding-bottom: 100px; }
  .hv:fullscreen .hv-end-h, .hv--overlay .hv-end-h { max-width: none; font-size: 18px; }
  .hv:fullscreen .hv-end-book, .hv--overlay .hv-end-book, .hv:fullscreen .hv-again, .hv--overlay .hv-again { min-height: 36px; }
}
@media (max-width: 599px) {
  .hv .mvid-ctl { gap: 0; padding: 12px 8px 4px; }
  .hv .mvid-row { gap: 4px; }
  .hv .mvid-btn { width: 30px; height: 30px; }
  .hv .mvid-btn--main { width: 32px; height: 32px; }
  .hv .mvid-ctl svg { width: 16px; height: 16px; }
}
