/* ProcureHub — product tour player (resources/views/tour/play.blade.php, assets/tour-player.js).
   The demo pages play in a full-screen frame; everything below is drawn on top of it. */
:root {
  --ink: #2D1B40; --ink-2: #45355A; --muted: #6A6078; --line: #E7E2EE; --ground: #F6F4F9;
  --accent: #6D2CD4; --accent-light: #B794F6; --accent-soft: #F4EEFD; --orange: #FD7E1E;
  --bar: #1E1429; --bar-2: #2E2140; --bar-line: #3D2F52; --bar-text: #DCD3EA; --bar-muted: #A497B8;
  --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { font-family: var(--font); color: var(--ink); background: var(--ground); overflow: hidden; -webkit-font-smoothing: antialiased; }
button { font: inherit; }
button:focus-visible { outline: 2px solid var(--accent-light); outline-offset: 2px; }

.t-demo-frame { position: fixed; inset: 0; width: 100%; height: 100%; border: 0; background: var(--ground); }

/* Blocks clicks on the demo while the tour plays (a click pauses instead). */
.t-block { position: fixed; inset: 0; z-index: 880; cursor: pointer; }

.t-spot { position: fixed; z-index: 890; border-radius: 14px; pointer-events: none; box-shadow: 0 0 0 9999px rgba(20, 12, 30, .58); transition: all .38s cubic-bezier(.4, 0, .2, 1); }
.t-spot::after { content: ""; position: absolute; inset: -4px; border-radius: 17px; border: 2px solid var(--accent-light); animation: t-ring 1.6s ease-out infinite; }
.t-spot.none { width: 0 !important; height: 0 !important; }
.t-spot.none::after { display: none; }
@keyframes t-ring { 0% { opacity: 1; transform: scale(1); } 100% { opacity: 0; transform: scale(1.06); } }

.t-pop { position: fixed; z-index: 900; width: 360px; background: #fff; border-radius: 18px; padding: 18px 20px 0; box-shadow: 0 22px 60px rgba(20, 12, 30, .35); transition: left .38s cubic-bezier(.4, 0, .2, 1), top .38s cubic-bezier(.4, 0, .2, 1), opacity .2s; overflow: hidden; }
.t-pop.hide { opacity: 0; pointer-events: none; }
.t-kick { display: flex; align-items: center; gap: 8px; font-size: 11.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--accent); }
.t-live { width: 8px; height: 8px; border-radius: 50%; background: #12B886; animation: t-live 1.4s infinite; flex: none; }
.t-pop.paused .t-live { background: #F59F00; animation: none; }
@keyframes t-live { 0% { box-shadow: 0 0 0 0 rgba(18, 184, 134, .6); } 70% { box-shadow: 0 0 0 7px rgba(18, 184, 134, 0); } 100% { box-shadow: 0 0 0 0 rgba(18, 184, 134, 0); } }
.t-title { font-size: 19px; font-weight: 700; margin: 8px 0 6px; letter-spacing: -.02em; }
.t-body { color: var(--ink-2); font-size: 14.5px; line-height: 1.55; }
.t-action { display: flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 13px; font-weight: 600; color: var(--accent); background: var(--accent-soft); border-radius: 10px; padding: 8px 12px; }
.t-timer { height: 4px; background: var(--ground); margin: 16px -20px 0; }
.t-timer i { display: block; height: 100%; width: 0; background: var(--accent); }
.t-pop::before { content: ""; position: absolute; width: 14px; height: 14px; background: #fff; transform: rotate(45deg); display: none; }
.t-pop.side-right::before { display: block; left: -6px; top: 26px; }
.t-pop.side-left::before { display: block; right: -6px; top: 26px; }
.t-pop.side-bottom::before { display: block; top: -6px; left: calc(50% - 7px); }
.t-pop.side-top::before { display: block; bottom: -6px; left: calc(50% - 7px); }
.t-pop.sheet { left: 12px !important; right: 12px; width: auto; }
.t-pop.sheet::before { display: none; }

.t-cursor { position: fixed; z-index: 960; left: 0; top: 0; width: 28px; height: 28px; pointer-events: none; transition: transform .62s cubic-bezier(.45, 0, .2, 1); filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .35)); display: none; }
.t-cursor.on { display: block; }
.t-ripple { position: fixed; z-index: 955; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: rgba(183, 148, 246, .8); pointer-events: none; animation: t-ripple .55s ease-out forwards; }
@keyframes t-ripple { to { transform: scale(4.2); opacity: 0; } }

/* Control bar */
.t-bar { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 950; width: min(860px, calc(100vw - 24px)); background: var(--bar); color: #fff; border-radius: 20px; padding: 12px 14px 12px 20px; box-shadow: 0 18px 50px rgba(20, 12, 30, .45); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 16px; align-items: center; }
.t-bar.top { bottom: auto; top: 12px; }
.t-info { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.t-info b { font-size: 14.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-info span { font-size: 12.5px; color: var(--bar-muted); white-space: nowrap; }
.t-tag { margin-left: auto; font-style: normal; font-size: 11px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--orange); border: 1px solid rgba(253, 126, 30, .45); border-radius: 999px; padding: 1px 8px; white-space: nowrap; }
.t-prog { grid-column: 1 / 2; display: flex; gap: 5px; }
.t-seg { flex: 1; height: 6px; border-radius: 99px; background: var(--bar-line); overflow: hidden; cursor: pointer; border: 0; padding: 0; position: relative; }
.t-seg i { position: absolute; inset: 0 auto 0 0; background: var(--accent-light); border-radius: 99px; transition: width .3s; }
.t-seg:hover { background: #54446B; }
.t-btns { grid-column: 2; grid-row: 1 / 3; display: flex; align-items: center; gap: 4px; }
.t-btn { width: 40px; height: 40px; border-radius: 50%; border: 0; background: none; color: var(--bar-text); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.t-btn:hover { background: var(--bar-2); color: #fff; }
.t-btn.play { width: 48px; height: 48px; background: #fff; color: var(--ink); }
.t-btn.play:hover { background: #EDE7F5; color: var(--ink); }
.t-speed { height: 34px; min-width: 50px; border-radius: 999px; border: 1px solid var(--bar-line); background: none; color: #fff; font-weight: 700; font-size: 13px; cursor: pointer; margin: 0 4px; }
.t-speed:hover { background: var(--bar-2); }

.t-chlist { position: fixed; z-index: 965; width: 300px; max-height: min(70vh, 520px); overflow: auto; background: var(--bar); border: 1px solid var(--bar-line); border-radius: 16px; padding: 8px; box-shadow: 0 18px 50px rgba(20, 12, 30, .45); }
.t-chlist button { display: flex; align-items: center; gap: 10px; width: 100%; border: 0; background: none; color: var(--bar-text); padding: 9px 10px; border-radius: 10px; cursor: pointer; font-weight: 600; font-size: 14px; text-align: left; }
.t-chlist button:hover, .t-chlist button.on { background: var(--bar-2); color: #fff; }
.t-chlist .n { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--bar-line); display: flex; align-items: center; justify-content: center; font-size: 12px; flex: none; }
.t-chlist .ok .n { background: var(--accent); border-color: var(--accent); color: #fff; }
.t-chlist small { margin-left: auto; color: var(--bar-muted); font-weight: 500; font-size: 12px; }

/* Start and end cards */
.t-overlay { position: fixed; inset: 0; z-index: 970; background: rgba(20, 12, 30, .62); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 16px; animation: t-fade .25s; }
@keyframes t-fade { from { opacity: 0; } }
.t-card { width: min(600px, 100%); background: #fff; border-radius: 26px; padding: 32px 34px 26px; box-shadow: 0 30px 80px rgba(20, 12, 30, .45); max-height: calc(100vh - 32px); overflow: auto; }
.t-card .logo { height: 36px; width: auto; display: block; margin-bottom: 20px; }
.t-card .kicker { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.t-card h2 { font-size: 30px; font-weight: 700; letter-spacing: -.03em; margin: 8px 0 10px; line-height: 1.15; text-wrap: balance; }
.t-card p { color: var(--ink-2); line-height: 1.6; margin: 0; }
.t-grid { list-style: none; padding: 0; margin: 20px 0 24px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.t-grid button { display: flex; gap: 10px; align-items: center; width: 100%; padding: 9px 10px; border-radius: 12px; background: var(--ground); border: 1px solid transparent; font-weight: 600; font-size: 14px; color: var(--ink); cursor: pointer; text-align: left; }
.t-grid button:hover { border-color: var(--accent-light); background: #fff; }
.t-grid small { display: block; color: var(--muted); font-weight: 500; font-size: 12px; }
.t-grid .n { width: 28px; height: 28px; border-radius: 50%; background: #fff; border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; font-size: 12.5px; font-weight: 700; flex: none; }
.t-grid .n.ok { background: var(--accent); border-color: var(--accent); color: #fff; }
.t-card .btns { display: flex; gap: 10px; flex-wrap: wrap; flex-direction: row-reverse; }
.t-card .btns .t-cta { flex: 1; }
.t-cta { height: 48px; padding: 0 20px; border-radius: 13px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-weight: 600; font-size: 15px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; text-decoration: none; }
.t-cta:hover { background: var(--ground); }
.t-cta.primary { background: var(--ink); border-color: var(--ink); color: #fff; }
.t-cta.primary:hover { background: #402C57; }
.t-card .note { font-size: 12.5px; color: var(--muted); margin-top: 14px; text-align: center; }

/* "Product tour" button when exploring the demo freely */
.t-fab { position: fixed; right: 18px; bottom: 18px; z-index: 650; background: var(--ink); color: #fff; border: 0; border-radius: 999px; height: 48px; padding: 0 20px 0 16px; font-weight: 600; display: flex; align-items: center; gap: 8px; cursor: pointer; box-shadow: 0 12px 30px -10px rgba(20, 12, 30, .6); }
.t-fab:hover { background: #402C57; }

@media (max-width: 700px) {
  .t-bar { grid-template-columns: 1fr; padding: 12px 14px; bottom: 10px; }
  .t-btns { grid-column: 1; grid-row: auto; justify-content: space-between; }
  .t-tag { display: none; }
  .t-card { padding: 24px 20px 20px; }
  .t-card h2 { font-size: 24px; }
  .t-grid { grid-template-columns: minmax(0, 1fr); }
  .t-grid small { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .t-spot, .t-pop, .t-cursor { transition: none; }
  .t-spot::after, .t-live { animation: none; }
}
