:root {
  --bg-0: #070b14;
  --bg-1: #0f172a;
  --bg-2: #111827;
  --text: #f8fafc;
  --muted: #94a3b8;
  --blue: #2563eb;
  --blue-soft: #60a5fa;
  --teal: #0d9488;
  --gold: #d4af73;
  --line: rgba(255, 255, 255, 0.12);
  --glass: rgba(255, 255, 255, 0.08);
  --glass-strong: rgba(255, 255, 255, 0.14);
  --shadow: 0 20px 60px rgba(2, 6, 23, 0.65);
}

* {
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

body {
  margin: 0;
  padding: 0;
  font-family: Inter, Arial, sans-serif;
  background:
    radial-gradient(circle at 20% 10%, rgba(37, 99, 235, 0.15), transparent 45%),
    radial-gradient(circle at 90% 30%, rgba(13, 148, 136, 0.12), transparent 50%),
    linear-gradient(160deg, var(--bg-0), var(--bg-1) 55%, var(--bg-2));
  color: var(--text);
  min-height: 100%;
  overflow-x: clip;
}

#fx-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

#cursor-glow {
  position: fixed;
  width: calc(420px * var(--pd-cursor-size-scale, 0.5));
  height: calc(420px * var(--pd-cursor-size-scale, 0.5));
  border-radius: 999px;
  pointer-events: none;
  z-index: 2;
  background: radial-gradient(
    circle,
    rgba(96, 165, 250, calc(0.45 * var(--pd-cursor-intensity, 1))),
    rgba(96, 165, 250, 0)
  );
  mix-blend-mode: screen;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.noise-layer {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.42;
  background-image:
    radial-gradient(rgba(255, 255, 255, 0.06) 0.5px, transparent 0.5px);
  background-size: 4px 4px;
}

.orb {
  position: fixed;
  border-radius: 999px;
  filter: blur(84px);
  z-index: 0;
  opacity: 0.65;
  pointer-events: none;
}

.orb-a {
  width: 500px;
  height: 500px;
  background: rgba(37, 99, 235, 0.62);
  top: -120px;
  left: -80px;
  animation: driftA 12s ease-in-out infinite;
}

.orb-b {
  width: 460px;
  height: 460px;
  background: rgba(13, 148, 136, 0.52);
  right: -100px;
  top: 140px;
  animation: driftB 16s ease-in-out infinite;
}

.orb-c {
  width: 520px;
  height: 520px;
  background: rgba(212, 175, 115, 0.28);
  left: 30%;
  bottom: -220px;
  animation: driftC 18s ease-in-out infinite;
}

@keyframes driftA {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(70px, 30px) scale(1.12); }
}

@keyframes driftB {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-90px, 40px) scale(1.08); }
}

@keyframes driftC {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-50px, -70px) scale(1.15); }
}

.topbar {
  position: relative;
  z-index: 15;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 40px;
  backdrop-filter: blur(16px);
  background: rgba(7, 11, 20, 0.66);
  border-bottom: 1px solid var(--line);
}

.brand {
  font-family: Sora, Inter, sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.brand-polar {
  color: #dbeafe;
}

.brand-draft {
  color: var(--blue-soft);
}

body.site-marketing,
body[data-pd-nav="public"] {
  --site-header-height: 84px;
  padding-top: var(--site-header-height);
  scroll-padding-top: var(--site-header-height);
}

body.site-marketing .topbar,
body[data-pd-nav="public"] .topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 50;
  box-sizing: border-box;
}

body.site-marketing .topbar,
body[data-pd-nav="public"] .topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px 20px;
}

body.site-marketing .topbar .menu,
body[data-pd-nav="public"] .topbar .menu {
  justify-content: center;
  flex-wrap: wrap;
  min-width: 0;
}

.menu {
  display: flex;
  gap: 10px 18px;
  align-items: center;
}

.menu-divider {
  width: 1px;
  height: 18px;
  background: rgba(148, 163, 184, 0.35);
  flex-shrink: 0;
  margin: 0 2px;
}

.topbar-signin.is-active {
  border-color: rgba(125, 211, 252, 0.55);
  color: #e0f2fe;
}

.menu a,
.footer a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.menu a:hover,
.footer a:hover {
  color: var(--text);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 12px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 600;
  padding: 13px 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-small {
  padding: 10px 14px;
  font-size: 0.92rem;
}

.btn-primary {
  color: white;
  background: linear-gradient(140deg, #1d4ed8, #2563eb 45%, #0d9488 120%);
  box-shadow: 0 14px 40px rgba(37, 99, 235, 0.35);
}

.btn-ghost {
  color: var(--text);
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.04);
}

main {
  width: min(1160px, calc(100% - 40px));
  margin: 0 auto;
  padding: 26px 0 80px;
}

.hero {
  padding: 90px 20px 70px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -45%;
  background: conic-gradient(
    from 0deg,
    rgba(96, 165, 250, 0.2),
    rgba(13, 148, 136, 0.08),
    rgba(212, 175, 115, 0.18),
    rgba(96, 165, 250, 0.2)
  );
  animation: heroSweep 13s linear infinite;
  pointer-events: none;
  opacity: 0.9;
}

.hero > * {
  position: relative;
  z-index: 1;
}

@keyframes heroSweep {
  from { transform: rotate(0deg) scale(1); }
  50% { transform: rotate(180deg) scale(1.05); }
  to { transform: rotate(360deg) scale(1); }
}

.eyebrow {
  color: var(--gold);
  letter-spacing: 0.14em;
  font-weight: 700;
  font-size: 0.74rem;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.12;
}

h1 {
  margin-top: 14px;
  font-size: clamp(2rem, 5.8vw, 4.2rem);
  font-family: Sora, Inter, sans-serif;
  text-wrap: balance;
}

h2 {
  font-size: clamp(1.5rem, 3.8vw, 2.6rem);
  font-family: Sora, Inter, sans-serif;
  text-wrap: balance;
}

h3 {
  font-size: 1.15rem;
}

.subtext {
  margin: 22px auto 0;
  max-width: 760px;
  color: #cbd5e1;
  font-size: 1.1rem;
  line-height: 1.7;
}

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

.trust-strip {
  margin-top: 28px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.trust-strip span {
  border: 1px solid var(--line);
  color: #bfdbfe;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 0.86rem;
}

.hero-stats {
  width: min(920px, 100%);
  margin: 30px auto 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03));
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
  padding: 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  transform-style: preserve-3d;
  animation: statsPulse 3.8s ease-in-out infinite;
}

@keyframes statsPulse {
  0%, 100% {
    box-shadow: var(--shadow), 0 0 0 rgba(96, 165, 250, 0);
  }
  50% {
    box-shadow: var(--shadow), 0 0 42px rgba(96, 165, 250, 0.32);
  }
}

.depth-grid {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0.25;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.11) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.11) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent 80%);
}

.tilt-card {
  position: relative;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  will-change: transform;
}

.stat-card {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.55);
  padding: 18px 14px;
  transform: translateZ(18px);
}

.stat-value {
  margin: 0;
  font-family: Sora, Inter, sans-serif;
  font-size: 1.7rem;
  color: #e2e8f0;
}

.stat-label {
  margin: 6px 0 0;
  color: #a5b4fc;
  font-size: 0.88rem;
}

.section {
  margin-top: 70px;
  padding: 20px 12px;
}

.section-head {
  text-align: center;
  margin-bottom: 30px;
}

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

.glass-card,
.price-card,
.faq-item {
  background: linear-gradient(155deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.glass-card {
  padding: 24px;
}

.glass-card p,
.center-copy,
.price-card li,
.faq-item p {
  color: #cbd5e1;
  line-height: 1.65;
}

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

.step {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.04);
}

.step span {
  display: inline-flex;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #dbeafe;
  background: linear-gradient(140deg, rgba(37, 99, 235, 0.5), rgba(13, 148, 136, 0.35));
  margin-bottom: 14px;
}

.center-copy {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.price-card {
  position: relative;
  padding: 24px;
}

.price-card .price {
  font-family: Sora, Inter, sans-serif;
  font-size: 1.9rem;
  margin: 14px 0;
}

.price-card .price span {
  font-size: 0.95rem;
  color: var(--muted);
  margin-left: 2px;
}

.price-card ul {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  display: grid;
  gap: 8px;
}

.featured {
  border-color: rgba(96, 165, 250, 0.5);
  background:
    linear-gradient(155deg, rgba(37, 99, 235, 0.25), rgba(13, 148, 136, 0.1));
}

.tag {
  position: absolute;
  right: 16px;
  top: 14px;
  margin: 0;
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #bfdbfe;
}

.faq-list {
  width: min(860px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 10px;
}

.faq-item {
  padding: 0;
  overflow: hidden;
}

.faq-item button {
  width: 100%;
  border: none;
  background: transparent;
  color: var(--text);
  text-align: left;
  font-weight: 600;
  cursor: pointer;
  font-size: 1rem;
  padding: 18px 20px;
  display: flex;
  justify-content: space-between;
}

.faq-item p {
  margin: 0;
  max-height: 0;
  overflow: hidden;
  padding: 0 20px;
  transition: max-height 0.25s ease, padding 0.25s ease;
}

.faq-item.open p {
  max-height: 180px;
  padding: 0 20px 18px;
}

.faq-item.open button span {
  transform: rotate(45deg);
}

.faq-item button span {
  transition: transform 0.2s ease;
}

.section-cta {
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 42px 24px;
  background: linear-gradient(140deg, rgba(37, 99, 235, 0.15), rgba(13, 148, 136, 0.08));
  box-shadow: var(--shadow);
}

.section-cta p {
  color: #bfdbfe;
}

.footer {
  margin: 40px auto 0;
  width: min(1160px, calc(100% - 40px));
  border-top: 1px solid var(--line);
  padding: 20px 0 50px;
  color: var(--muted);
  text-align: center;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin: 10px 0 8px;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Legal pages */
.legal-wrap {
  width: min(980px, calc(100% - 34px));
  margin: 34px auto 60px;
}

.legal-wrap.app-wrap {
  width: var(--page-width);
  max-width: calc(100% - 2 * var(--page-edge, 2rem));
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

body.luxe .legal-wrap.app-wrap,
body.luxe .luxe-main {
  width: var(--page-width);
  max-width: calc(100% - 2 * var(--page-edge));
}

body.luxe .footer {
  width: var(--page-width);
  max-width: calc(100% - 2 * var(--page-edge));
}

.legal-header {
  margin-bottom: 24px;
}

.legal-header h1 {
  font-size: clamp(1.6rem, 4vw, 2.7rem);
}

.legal-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  padding: 22px;
  margin-bottom: 14px;
}

.legal-card h2 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.legal-card p,
.legal-card li {
  color: #d1d5db;
  line-height: 1.7;
}

@media (max-width: 960px) {
  body.site-marketing .menu,
  body[data-pd-nav="public"] .menu,
  body.app-page .topbar .menu,
  body[data-pd-nav="company-login"] .topbar .menu,
  body[data-pd-nav="company-workspace"] .topbar .menu,
  body[data-pd-nav="platform-owner"] .topbar .menu,
  body[data-pd-nav="minimal"] .topbar .menu {
    display: none;
  }

  .card-grid,
  .pricing-grid,
  .timeline {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .topbar {
    padding: 14px 16px;
  }

  main,
  .footer {
    width: calc(100% - 20px);
  }
}
