/* ---------- Public landing page ---------- */
.public .site-header .header-right { gap: 8px; }
.public-nav { margin-left: 12px; }

.landing { overflow-x: clip; }
.hero {
  position: relative; padding-block: 64px 72px;
  background:
    radial-gradient(48rem 26rem at 85% 10%, color-mix(in srgb, var(--brand-2) 16%, transparent), transparent 70%),
    radial-gradient(52rem 28rem at 5% 0%, color-mix(in srgb, var(--primary) 16%, transparent), transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 48px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow);
  font-size: var(--fs-sm); font-weight: 600; color: var(--ink-2);
}
.eyebrow .icon { color: var(--accent); }
.hero h1 { font-size: clamp(34px, 5.2vw, 56px); line-height: 1.08; letter-spacing: -.035em; margin: 20px 0 18px; }
.grad {
  background: linear-gradient(100deg, var(--primary), var(--brand-2) 60%, var(--accent));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-lead { font-size: 19px; color: var(--ink-2); max-width: 56ch; margin-bottom: 28px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-cta .btn-primary {
  background: linear-gradient(135deg, #3D6BFF, #7C3AED); color: #fff; border: 0;
  box-shadow: 0 8px 24px rgb(76 80 240 / .35);
}
.hero-cta .btn-primary:hover { filter: brightness(1.08); }
.hero-stats { display: flex; flex-wrap: wrap; gap: 12px 36px; margin: 36px 0 0; }
.hero-stats div { display: flex; flex-direction: column-reverse; }
.hero-stats dt { color: var(--ink-2); font-size: var(--fs-md); }
.hero-stats dd { margin: 0; font-size: 30px; font-weight: 800; letter-spacing: -.03em; line-height: 1.2; }

/* product preview */
.hero-demo { position: relative; padding: 24px 12px; }
.demo-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 22px;
  box-shadow: 0 30px 60px -20px rgb(20 24 60 / .30), var(--shadow);
  transform: rotate(1.5deg);
}
.demo-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.demo-progress { margin-left: auto; font-size: var(--fs-sm); color: var(--ink-2); font-weight: 600; }
.demo-q { font-weight: 700; font-size: 18px; margin-bottom: 10px; }
.demo-code { margin: 0 0 14px; padding: 14px 16px; border-radius: 12px; background: light-dark(#14171F, #0B0D12); color: #E6E9F2; font-size: 14px; line-height: 1.6; overflow-x: auto; }
.demo-code code { background: none; padding: 0; color: inherit; }
.demo-options { list-style: none; padding: 0; margin: 0 0 14px; display: grid; gap: 8px; }
.demo-options li {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border: 1px solid var(--border); border-radius: 12px; font-size: var(--fs-md);
}
.demo-options b { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--surface-2); font-size: 13px; }
.demo-options .ok { border-color: var(--success); background: var(--success-bg); color: var(--success-text); font-weight: 600; }
.demo-options .ok b { background: var(--success); color: #fff; }
.demo-options .ok .icon { margin-left: auto; }
.demo-why { margin: 0; font-size: var(--fs-sm); color: var(--ink-2); padding: 10px 12px; border-left: 3px solid var(--primary); background: color-mix(in srgb, var(--primary) 6%, transparent); border-radius: 0 10px 10px 0; }
.demo-float {
  position: absolute; display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border);
  box-shadow: var(--shadow-up); font-size: var(--fs-md); white-space: nowrap;
  animation: td-float 5s ease-in-out infinite;
}
.demo-streak { top: 0; left: -8px; }
.demo-streak .icon { color: var(--accent); }
.demo-goal { bottom: 4px; right: -4px; animation-delay: -2.5s; }
.demo-goal .icon { color: var(--success); }
@keyframes td-float { 50% { transform: translateY(-8px); } }

/* sections */
.landing-section { padding-block: 56px 8px; scroll-margin-top: calc(var(--header-h) + 8px); }
.landing-head { text-align: center; max-width: 640px; margin: 0 auto 32px; }
.landing-head h2 { font-size: clamp(26px, 3.4vw, 36px); letter-spacing: -.03em; }
.feature-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); }
.feature {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px;
  transition: transform .16s ease, box-shadow .16s ease;
}
.feature:hover { transform: translateY(-3px); box-shadow: var(--shadow-up); }
.feature h3 { font-size: 18px; margin: 16px 0 6px; }
.feature p { margin: 0; color: var(--ink-2); font-size: var(--fs-md); }
.feature-icon {
  width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--tone) 14%, transparent); color: color-mix(in oklab, var(--tone) 75%, var(--ink));
}
.feature-icon .icon { width: 22px; height: 22px; }
.topic-desc { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); counter-reset: none; }
.steps li { position: relative; padding: 24px; border-radius: var(--radius); border: 1px dashed var(--border); }
.steps h3 { font-size: 18px; margin: 14px 0 6px; }
.steps p { margin: 0; color: var(--ink-2); font-size: var(--fs-md); }
.step-no {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
  font-weight: 800; color: #fff; background: linear-gradient(135deg, #3D6BFF, #7C3AED);
}

.cta-band {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px;
  padding: 40px; border-radius: 24px; color: #fff; position: relative; overflow: hidden;
  background: linear-gradient(120deg, #2F5BEA 0%, #6D3CE6 60%, #A43FD0 100%);
}
.cta-band::after { content: ""; position: absolute; right: -80px; top: -120px; width: 320px; height: 320px; border-radius: 50%;
  border: 50px solid rgb(255 255 255 / .08); pointer-events: none; }
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 { margin: 0 0 6px; font-size: clamp(22px, 3vw, 30px); }
.cta-band p { margin: 0; opacity: .9; }
.cta-band .btn { background: #fff; color: #1B1F24; }
.cta-band .btn:hover { background: #EEF1FD; }

@media (max-width: 960px) {
  .hero { padding-block: 40px 48px; }
  .hero-grid { grid-template-columns: 1fr; gap: 32px; }
  .hero-demo { max-width: 520px; }
}

/* Public header on tablets and phones: logo + both account buttons on the first row,
   the section links as a scrollable strip on the second row (instead of disappearing). */
@media (max-width: 960px) {
  .public .site-header .container { flex-wrap: wrap; height: auto; row-gap: 0; padding-top: 10px; }
  .public .site-header .logo { min-height: 40px; }
  .public .site-header .header-right { margin-left: auto; }
  .public .pub-login { border: 1px solid var(--border); background: var(--surface); color: var(--ink); }
  .public .public-nav {
    display: flex; order: 3; flex-basis: 100%; margin: 0 calc(var(--gutter) * -1); padding: 6px var(--gutter) 8px;
    overflow-x: auto; scrollbar-width: none; gap: 4px; -webkit-overflow-scrolling: touch;
  }
  .public .public-nav::-webkit-scrollbar { display: none; }
  .public .public-nav a { padding: 6px 12px; font-size: 14px; border-radius: 999px; background: var(--surface-2); flex: none; }
  .public .landing-section { scroll-margin-top: calc(var(--header-h) + 52px); }
}
@media (max-width: 480px) {
  .public .pub-free { display: none; }
}
@media (max-width: 360px) {
  .public .logo-word { display: none; }
}
@media (max-width: 480px) {
  .cta-band { padding: 28px 24px; }
  .demo-float { display: none; }
}
