/* ====== AI Workforce for Tenders — Microsoft demo prototype ====== */

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; overflow: hidden; }
body {
  font-family: "Segoe UI Variable", "Segoe UI", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  color: #242424;
  background: #0b1538;
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button { font-family: inherit; cursor: pointer; }

/* ====== Desktop / stage ====== */
.desktop {
  position: fixed; inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0b1538;
}

.stage {
  width: 1920px;
  height: 1080px;
  position: relative;
  transform-origin: center center;
  background:
    radial-gradient(1200px 800px at 70% 30%, #6a8fe0 0%, transparent 60%),
    radial-gradient(900px 700px at 20% 80%, #1f3aa8 0%, transparent 50%),
    linear-gradient(160deg, #0b1538 0%, #1a2a6d 100%);
  overflow: hidden;
}

/* App window fills above taskbar (taskbar is 56px) */
.app-window {
  position: absolute;
  inset: 0 0 56px 0;
  background: #fff;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.app-window.outlook { background: #faf9f8; }
.app-window.teams { background: #f5f5f5; }
.app-window.whatsapp { background: #efeae2; }

/* ====== Windows-style taskbar ====== */
.taskbar {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 56px;
  background: rgba(243, 243, 243, 0.92);
  backdrop-filter: blur(40px) saturate(180%);
  border-top: 1px solid rgba(0,0,0,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 100;
}
.taskbar-left,
.taskbar-right {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 200px;
}
.taskbar-right { justify-content: flex-end; }
.taskbar-apps {
  display: flex;
  align-items: center;
  gap: 4px;
}

.tb-item {
  width: 42px; height: 42px;
  border-radius: 6px;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: background 0.12s;
  padding: 0;
}
.tb-item:hover { background: rgba(0,0,0,0.05); }
.tb-item.active { background: rgba(0,0,0,0.04); }
.tb-item.active::after {
  content: "";
  position: absolute;
  bottom: 3px;
  left: 50%;
  transform: translateX(-50%);
  width: 16px; height: 3px;
  border-radius: 2px;
  background: #0078d4;
}
.tb-item img,
.tb-item svg { width: 28px; height: 28px; }
.tb-time {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-size: 12px;
  line-height: 1.3;
  color: #1f1f1f;
  padding: 0 12px 0 8px;
  font-weight: 400;
}
.tb-tray {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 8px;
  color: #555;
}

/* ====== Demo controls ====== */
.demo-ctrls {
  position: absolute;
  top: 16px; right: 16px;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 8px;
  background: rgba(15, 23, 42, 0.85);
  color: #fff;
  border-radius: 100px;
  padding: 6px 8px 6px 16px;
  backdrop-filter: blur(20px);
  font-size: 12px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}
.demo-ctrls .step-label {
  font-weight: 600;
  letter-spacing: 0.02em;
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  white-space: nowrap;
}
.demo-ctrls .step-label .sm {
  font-size: 10px;
  font-weight: 500;
  opacity: 0.6;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.demo-ctrls button {
  background: rgba(255,255,255,0.12);
  color: #fff;
  border: none;
  border-radius: 100px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.demo-ctrls button:hover:not(:disabled) { background: rgba(255,255,255,0.22); }
.demo-ctrls button:disabled { opacity: 0.35; cursor: default; }
.demo-ctrls button.primary {
  background: #7b44ff;
  color: #fff;
}
.demo-ctrls button.primary:hover { background: #8e5fff; }
.demo-ctrls .divider { width: 1px; height: 18px; background: rgba(255,255,255,0.18); margin: 0 4px; }

/* ====== Hotspot pulse ====== */
.hotspot-wrap { position: relative; display: inline-flex; }
.hotspot-ring {
  position: absolute;
  inset: -6px;
  border-radius: inherit;
  pointer-events: none;
  box-shadow: 0 0 0 0 rgba(123, 68, 255, 0.55);
  animation: hotspot-pulse 1.8s infinite;
  border-radius: 10px;
}
@keyframes hotspot-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(123, 68, 255, 0.55); }
  70%  { box-shadow: 0 0 0 14px rgba(123, 68, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(123, 68, 255, 0); }
}

/* ====== Shared scrollbar ====== */
.scrollable { overflow-y: auto; }
.scrollable::-webkit-scrollbar { width: 10px; height: 10px; }
.scrollable::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.18); border-radius: 10px; border: 2px solid transparent; background-clip: content-box; }
.scrollable::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.28); background-clip: content-box; border: 2px solid transparent; }

/* ====== Common ====== */
.fade-in { animation: fade-in 0.4s ease-out both; }
.slide-in { animation: slide-in 0.45s cubic-bezier(.2,.7,.2,1) both; }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes slide-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* ====== Journey rail ====== */
.journey-rail {
  position: absolute;
  top: 16px; left: 16px; bottom: 72px;
  z-index: 150;
  display: flex;
  align-items: stretch;
  pointer-events: none;
}
.journey-rail .jr-toggle {
  position: absolute;
  top: 6px; left: 0;
  width: 28px; height: 28px;
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.85);
  color: #fff;
  border: none;
  font-size: 14px;
  cursor: pointer;
  pointer-events: auto;
  box-shadow: 0 4px 12px rgba(0,0,0,0.25);
}
.journey-rail .jr-toggle:hover { background: rgba(15, 23, 42, 1); }
.journey-rail .jr-panel {
  width: 280px;
  margin-left: 36px;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(20px);
  color: #fff;
  border-radius: 12px;
  padding: 18px 14px 14px;
  overflow-y: auto;
  box-shadow: 0 12px 32px rgba(0,0,0,0.28);
  pointer-events: auto;
  opacity: 0; transform: translateX(-8px);
  transition: opacity 0.2s, transform 0.2s;
}
.journey-rail.open .jr-panel { opacity: 1; transform: translateX(0); }
.journey-rail:not(.open) .jr-panel { pointer-events: none; }
.journey-rail .jr-title {
  font-size: 14px; font-weight: 700; letter-spacing: 0.01em;
}
.journey-rail .jr-sub {
  font-size: 11px; color: rgba(255,255,255,0.55); margin-bottom: 16px; letter-spacing: 0.04em; text-transform: uppercase;
}
.journey-rail .jr-stage {
  margin-bottom: 14px;
}
.journey-rail .jr-stage-num {
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em;
  color: rgba(255,255,255,0.45); text-transform: uppercase;
  padding: 0 6px 4px;
}
.journey-rail .jr-step {
  display: flex; gap: 10px;
  width: 100%;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.7);
  text-align: left;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
}
.journey-rail .jr-step:hover { background: rgba(255,255,255,0.06); }
.journey-rail .jr-step.active { background: rgba(123,68,255,0.22); color: #fff; }
.journey-rail .jr-step.done { color: rgba(255,255,255,0.85); }
.journey-rail .jr-dot {
  width: 8px; height: 8px; border-radius: 50%;
  margin-top: 6px; flex-shrink: 0;
}
.journey-rail .jr-step-label { font-size: 12.5px; font-weight: 600; }
.journey-rail .jr-step-desc { font-size: 11px; color: rgba(255,255,255,0.55); margin-top: 1px; line-height: 1.35; }

/* Hyperhumans agent avatar mark */
.h-mark {
  width: 100%; height: 100%;
  border-radius: 50%;
  background: #0d0d0d;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: -0.02em;
  font-family: "Segoe UI", sans-serif;
}
.h-mark::before {
  content: "H";
  background: linear-gradient(135deg, #7b44ff, #b785ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Title row in chat bubbles */
.muted { color: #616161; }
.linkish { color: #0067c0; cursor: pointer; }
.linkish:hover { text-decoration: underline; }

/* Small typing dots */
.typing { display: inline-flex; align-items: center; gap: 4px; }
.typing span { width: 6px; height: 6px; border-radius: 50%; background: #7b44ff; animation: bounce 1.2s infinite ease-in-out; }
.typing span:nth-child(2) { animation-delay: 0.15s; }
.typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes bounce {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}
