:root {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --ink: #111827;
  --muted: #697386;
  --line: #e5e9f0;
  --accent: #00d9c0;
  --accent-2: #179cf0;
  --good: #16a34a;
  --shadow: 0 20px 60px rgba(15, 23, 32, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(rgba(17, 24, 39, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(17, 24, 39, 0.025) 1px, transparent 1px),
    var(--bg);
  background-size: 40px 40px;
  color: var(--ink);
  font-family: "Roboto", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

.demo-shell {
  min-height: 100vh;
}

.demo-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px clamp(18px, 4vw, 48px);
  border-bottom: 1px solid rgba(229, 233, 240, 0.88);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(18px);
}

.brand,
.demo-header nav,
.hero-actions,
.panel-head,
.lp-card dl,
.ai-layout,
.artifact-layout,
.dashboard-grid {
  display: flex;
}

.brand {
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 850;
}

.brand-mark {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 10px 24px rgba(0, 217, 192, 0.28);
}

.demo-header nav {
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f2f5f9;
}

.demo-header nav a,
.header-cta,
.primary-link,
.secondary-link,
.lp-card a {
  text-decoration: none;
  font-size: 13px;
  font-weight: 760;
}

.demo-header nav a {
  padding: 8px 12px;
  border-radius: 999px;
  color: #465264;
}

.demo-header nav a:hover {
  background: #fff;
  color: var(--ink);
}

.header-cta,
.primary-link {
  border-radius: 10px;
  background: #111827;
  color: #fff;
}

.header-cta {
  padding: 10px 14px;
}

.hero,
.section-block {
  width: min(1180px, calc(100% - 36px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1.1fr);
  gap: 34px;
  align-items: center;
  min-height: calc(100vh - 74px);
  padding: 58px 0 38px;
}

.eyebrow {
  margin: 0 0 12px;
  color: #089987;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1,
.section-head h2 {
  margin: 0;
  line-height: 1.04;
  letter-spacing: 0;
}

.hero h1 {
  font-size: clamp(44px, 6vw, 72px);
}

.hero-copy > p:not(.eyebrow),
.section-head p {
  color: var(--muted);
  line-height: 1.8;
}

.hero-copy > p:not(.eyebrow) {
  max-width: 620px;
  margin: 22px 0 0;
  font-size: 16px;
}

.hero-actions {
  gap: 12px;
  margin-top: 30px;
  flex-wrap: wrap;
}

.primary-link,
.secondary-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
}

.secondary-link {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
}

.hero-visual,
.panel,
.metric-card,
.lp-card {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero-visual {
  overflow: hidden;
  border-radius: 16px;
}

.mini-topbar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfe;
}

.mini-topbar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d5dbe5;
}

.mini-topbar strong {
  margin-left: auto;
  color: var(--muted);
  font-size: 12px;
}

.mini-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 18px;
}

.mini-card {
  min-height: 128px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}

.mini-card.wide {
  grid-column: 1 / -1;
}

.mini-card span,
.metric-card span,
.panel-head span,
.lp-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.mini-card strong,
.metric-card strong {
  display: block;
  margin-top: 10px;
  font-size: 32px;
  line-height: 1;
}

.mini-card p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.sparkline {
  display: flex;
  align-items: end;
  gap: 8px;
  height: 76px;
  margin-top: 12px;
}

.sparkline i {
  flex: 1;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
}

.heatmap-preview {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fafc;
}

.heatmap-preview b {
  aspect-ratio: 1;
  border-radius: 10px;
  background: rgba(0, 217, 192, 0.18);
}

.heatmap-preview b:nth-child(3n),
.heatmap-preview b:nth-child(7) {
  background: rgba(23, 156, 240, 0.42);
}

.heatmap-preview b:nth-child(5),
.heatmap-preview b:nth-child(10) {
  background: rgba(0, 217, 192, 0.62);
}

.section-block {
  padding: 54px 0;
}

.section-head {
  max-width: 760px;
  margin-bottom: 24px;
}

.section-head h2 {
  font-size: clamp(30px, 4vw, 48px);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.metric-card {
  min-height: 138px;
  padding: 20px;
  border-radius: 12px;
}

.metric-card em {
  display: inline-flex;
  margin-top: 16px;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(0, 217, 192, 0.12);
  color: #087f74;
  font-size: 12px;
  font-style: normal;
  font-weight: 850;
}

.dashboard-grid {
  gap: 16px;
  margin-top: 16px;
}

.dashboard-grid > .panel:first-child {
  flex: 1.3;
}

.dashboard-grid > .panel:last-child {
  flex: 0.8;
}

.panel {
  border-radius: 12px;
  padding: 20px;
}

.panel-head {
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.panel h3 {
  margin: 0;
  font-size: 18px;
}

.bar-chart {
  display: grid;
  gap: 14px;
}

.bar-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 52px;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  font-weight: 760;
}

.bar-row div {
  overflow: hidden;
  height: 12px;
  border-radius: 999px;
  background: #edf1f6;
}

.bar-row i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
}

.demo-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.demo-table th,
.demo-table td {
  padding: 12px 8px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

.demo-table th {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
}

.lp-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.lp-card {
  overflow: hidden;
  border-radius: 12px;
}

.lp-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.lp-card > div {
  padding: 18px;
}

.lp-card h3 {
  margin: 8px 0 8px;
  font-size: 20px;
}

.lp-card p {
  min-height: 78px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.lp-card dl {
  justify-content: space-between;
  gap: 10px;
  margin: 18px 0;
}

.lp-card dt {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  text-transform: uppercase;
}

.lp-card dd {
  margin: 3px 0 0;
  font-weight: 850;
}

.lp-card a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
}

.artifact-layout {
  display: grid;
  grid-template-columns: 1fr 0.9fr 1fr;
  gap: 16px;
}

.funnel {
  display: grid;
  gap: 12px;
}

.funnel-row span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

.funnel-row div {
  min-width: 84px;
  padding: 10px 12px;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 850;
  text-align: right;
}

.heatmap-phone {
  position: relative;
  overflow: hidden;
  width: min(260px, 100%);
  margin: 0 auto;
  border: 10px solid #111827;
  border-radius: 28px;
  background: #111827;
}

.heatmap-phone img {
  display: block;
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  opacity: 0.86;
}

.heat {
  position: absolute;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(255, 55, 95, 0.58);
  box-shadow: 0 0 30px rgba(255, 55, 95, 0.75);
}

.h1 { left: 54%; top: 18%; }
.h2 { left: 22%; top: 46%; width: 74px; height: 74px; }
.h3 { left: 58%; top: 63%; background: rgba(0, 217, 192, 0.62); box-shadow: 0 0 30px rgba(0, 217, 192, 0.75); }
.h4 { left: 38%; top: 82%; width: 92px; height: 92px; }

.task-list {
  display: grid;
  gap: 12px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.task-list li {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fbfcfe;
}

.task-list strong,
.task-list span {
  display: block;
}

.task-list span {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.ai-section {
  padding-bottom: 90px;
}

.ai-layout {
  gap: 16px;
  align-items: stretch;
}

.question-list {
  display: grid;
  gap: 10px;
  width: 330px;
}

.question-list button {
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  padding: 0 14px;
  text-align: left;
  font: inherit;
  font-weight: 800;
}

.question-list button.active {
  border-color: rgba(0, 217, 192, 0.8);
  box-shadow: 0 0 0 3px rgba(0, 217, 192, 0.12);
}

.ai-answer {
  flex: 1;
  min-height: 250px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow);
}

.ai-answer span {
  color: #087f74;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ai-answer h3 {
  margin: 12px 0;
  font-size: 24px;
}

.ai-answer p {
  margin: 0;
  color: #334155;
  line-height: 1.9;
}

.answer-evidence {
  margin-top: 18px;
  padding: 14px;
  border-radius: 12px;
  background: #f2fbfa;
}

.answer-evidence b,
.answer-evidence small {
  display: block;
}

.answer-evidence small {
  margin-top: 5px;
  color: var(--muted);
}

@media (max-width: 980px) {
  .demo-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .metric-grid,
  .lp-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-grid,
  .ai-layout {
    flex-direction: column;
  }

  .question-list {
    width: 100%;
  }

  .artifact-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .demo-header nav {
    width: 100%;
    overflow-x: auto;
    justify-content: flex-start;
  }

  .hero,
  .section-block {
    width: min(100% - 24px, 1180px);
  }

  .metric-grid,
  .lp-grid,
  .mini-grid {
    grid-template-columns: 1fr;
  }

  .bar-row {
    grid-template-columns: 1fr;
  }
}

/* App-aligned demo launcher */
.demo-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  background: var(--bg);
}

.demo-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  border-right: 1px solid var(--line);
  background: #fff;
}

.demo-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
}

.demo-brand strong,
.demo-brand small {
  display: block;
}

.demo-brand strong {
  font-size: 14px;
}

.demo-brand small {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}

.demo-nav {
  display: grid;
  gap: 4px;
  padding: 14px 12px;
}

.demo-nav a {
  display: flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border-radius: 7px;
  color: #475569;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}

.demo-nav a:hover {
  background: #f8fafc;
  color: var(--ink);
}

.demo-main {
  min-width: 0;
  padding: 24px;
}

.demo-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 92px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.demo-topbar h1 {
  margin: 0;
  font-size: 28px;
  line-height: 1.3;
}

.btn.primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
}

.notice-panel {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  background: #eff6ff;
  color: #1e40af;
  font-size: 13px;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(360px, 0.9fr);
  gap: 16px;
  margin-top: 16px;
}

.workspace-grid.lower {
  grid-template-columns: minmax(0, 1fr) minmax(420px, 0.9fr);
}

.project-panel .panel-head,
.flow-panel .panel-head {
  margin-bottom: 14px;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(0, 217, 192, 0.12);
  color: #087f74;
  font-size: 11px;
  font-weight: 600;
}

.project-preview {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
}

.preview-thumb {
  aspect-ratio: 4 / 3;
  border-radius: 10px;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.05), rgba(15, 23, 42, 0.42)),
    url("https://images.unsplash.com/photo-1522337360788-8b13dee7a37e?auto=format&fit=crop&w=600&q=80") center / cover;
}

.project-preview h3 {
  margin: 0 0 8px;
  font-size: 20px;
}

.project-preview p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-top: 18px;
}

.metric-row div {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f8fafc;
}

.metric-row span,
.metric-row strong {
  display: block;
}

.metric-row span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
}

.metric-row strong {
  margin-top: 6px;
  font-size: 22px;
  font-weight: 600;
}

.flow-list {
  display: grid;
  gap: 8px;
}

.flow-list a {
  display: grid;
  grid-template-columns: 34px 1fr;
  column-gap: 10px;
  align-items: center;
  min-height: 58px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  text-decoration: none;
}

.flow-list a:hover {
  border-color: rgba(0, 217, 192, 0.75);
  box-shadow: 0 0 0 3px rgba(0, 217, 192, 0.1);
}

.flow-list span {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
}

.flow-list strong,
.flow-list small {
  display: block;
}

.flow-list strong {
  font-size: 13px;
  font-weight: 600;
}

.flow-list small {
  margin-top: 2px;
  color: var(--muted);
}

.lp-grid.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.lp-grid.compact .lp-card p,
.lp-grid.compact .lp-card dl {
  display: none;
}

.lp-grid.compact .lp-card h3 {
  font-size: 15px;
}

.lp-grid.compact .lp-card img {
  aspect-ratio: 16 / 9;
}

.lp-index {
  width: min(920px, calc(100% - 36px));
  margin: 0 auto;
  padding: 64px 0;
}

.lp-index-head {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--shadow);
}

.lp-index-head h1 {
  margin: 0;
  font-size: 32px;
}

.lp-index-head p:not(.eyebrow) {
  color: var(--muted);
}

.lp-index-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.lp-index-grid a {
  display: grid;
  place-items: center;
  min-height: 96px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  text-decoration: none;
  font-weight: 600;
}

@media (max-width: 980px) {
  .demo-page {
    grid-template-columns: 1fr;
  }

  .demo-sidebar {
    position: static;
    height: auto;
  }

  .demo-nav {
    grid-template-columns: repeat(3, 1fr);
  }

  .workspace-grid,
  .workspace-grid.lower {
    grid-template-columns: 1fr;
  }

  .lp-index-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Sharper sales demo tone */
.demo-hero {
  background:
    radial-gradient(circle at top left, rgba(6, 182, 212, 0.22), transparent 36%),
    linear-gradient(135deg, #0f172a 0%, #111827 52%, #164e63 100%);
  border-color: rgba(6, 182, 212, 0.28);
  color: #ffffff;
  overflow: hidden;
}

.demo-hero .eyebrow,
.demo-hero .hero-copy {
  color: rgba(255, 255, 255, 0.72);
}

.demo-hero h1 {
  max-width: 860px;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.hero-copy {
  max-width: 720px;
  margin: 16px 0 0;
  font-size: 15px;
  line-height: 1.9;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 190px;
}

.hero-actions .btn.primary {
  min-height: 48px;
  background: #06b6d4;
  color: #06202a;
  font-weight: 800;
}

.hero-actions .btn.secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.56);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 700;
}

.demo-sidebar {
  background: #0f172a;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.demo-brand {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.demo-brand small,
.demo-nav a {
  color: rgba(255, 255, 255, 0.62);
}

.demo-nav a:hover {
  background: rgba(6, 182, 212, 0.14);
  color: #ffffff;
}

@media (max-width: 760px) {
  .hero-actions {
    width: 100%;
  }
}
