/* Home page (/): what it is, sign in, create a store. Builds on the tokens and buttons in app.css.
   One vertical rhythm: 72px between blocks on desktop, 48px on tablets, 40px on phones (--gap). */
.home { --gap: 72px; background: var(--surface); color: var(--text); font-size: 16px; overflow-x: hidden; }
.home-wrap { width: min(1120px, 100%); margin: 0 auto; padding: 0 24px; }
.skip-link { position: absolute; top: -48px; left: 16px; z-index: 30; padding: 8px 14px; border-radius: var(--radius-sm); background: var(--text); color: #fff; font-weight: 600; }
.skip-link:focus { top: 12px; }
.home a:focus-visible, .home .btn:focus-visible { outline: 3px solid rgba(79, 70, 229, .45); outline-offset: 2px; }

/* Sign-up state is known after /public/platform answers; keep the buttons' space until then. */
.home:not(.is-ready) .cta { visibility: hidden; }
.btn-xl { height: 52px; padding: 0 24px; border-radius: 11px; font-size: 16px; }
.btn-xl .icon { width: 18px; height: 18px; }
.btn-light { background: #fff; color: var(--primary-hover); box-shadow: 0 1px 2px rgba(16, 24, 40, .12); }
.btn-light:hover { background: var(--primary-soft); }

/* ---------- top bar ---------- */
.home-top { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid rgba(229, 231, 235, .7); background: rgba(255, 255, 255, .85); backdrop-filter: saturate(180%) blur(12px); -webkit-backdrop-filter: saturate(180%) blur(12px); }
.home-top-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 64px; }
.home .brand { font-size: 16px; letter-spacing: -.01em; }
.home a.brand:hover { text-decoration: none; }
.home-top-actions { display: flex; align-items: center; gap: 6px; }
.home-signin { color: var(--text); }

/* ---------- hero ---------- */
.hero { padding: 64px 0 var(--gap); background: radial-gradient(900px 480px at 0% 0%, #eef2ff 0%, transparent 65%), radial-gradient(700px 420px at 100% 30%, #fdf2f8 0%, transparent 60%), var(--surface); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.hero h1 { max-width: 12ch; font-size: clamp(36px, 4.6vw, 56px); font-weight: 750; line-height: 1.05; letter-spacing: -.035em; }
.hero-lead { max-width: 30em; margin-top: 20px; color: #4b5563; font-size: clamp(17px, 1.5vw, 19px); line-height: 1.6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-actions .btn-primary { box-shadow: 0 8px 20px -8px rgba(79, 70, 229, .6); }
.trust { display: flex; align-items: center; gap: 8px; margin-top: 20px; color: var(--text-muted); font-size: 14px; font-weight: 600; }
.trust svg { width: 18px; height: 18px; flex: none; fill: none; stroke: var(--success); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Illustration: the assistant answering a shopper, built from plain elements. */
.hero-visual { position: relative; padding-bottom: 24px; }
.demo-window { overflow: hidden; border: 1px solid var(--border); border-radius: 18px; background: var(--surface); box-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 32px 64px -24px rgba(30, 27, 75, .28); font-size: 14px; }
.demo-bar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--border); background: var(--surface-muted); }
.demo-bar .brand-mark { width: 26px; height: 26px; border-radius: 8px; }
.demo-bar .brand-mark .icon { width: 14px; height: 14px; }
.demo-tabs { display: flex; gap: 4px; margin-left: auto; color: var(--text-muted); font-size: 12px; font-weight: 600; }
.demo-tabs span { padding: 4px 10px; border-radius: 999px; }
.demo-tabs .is-on { background: var(--primary-soft); color: var(--primary-hover); }
.demo-body { display: flex; flex-direction: column; gap: 12px; padding: 20px; }
.demo-ask { align-self: flex-end; max-width: 85%; padding: 10px 14px; border-radius: 16px 16px 4px 16px; background: var(--primary); color: #fff; }
.demo-reply { align-self: flex-start; max-width: 85%; color: var(--text); }
.demo-who { display: flex; align-items: center; gap: 6px; margin-bottom: 2px; color: var(--primary-hover); font-size: 12px; font-weight: 700; }
.demo-who .icon { width: 13px; height: 13px; }
.demo-product { display: grid; grid-template-columns: 136px minmax(0, 1fr); gap: 16px; padding: 12px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); }
.demo-photo { display: grid; place-items: center; min-height: 148px; border-radius: 10px; background: linear-gradient(150deg, #e0e7ff 0%, #f5f3ff 45%, #fce7f3 100%); }
.demo-photo svg { width: 78%; max-width: 112px; }
.demo-photo .jacket { fill: #4f46e5; }
.demo-photo .jacket-line { fill: none; stroke: #c7d2fe; stroke-width: 2.5; stroke-linecap: round; }
.demo-info { display: flex; flex-direction: column; min-width: 0; }
.demo-name { font-size: 15px; font-weight: 650; }
.demo-price { margin-top: 2px; font-size: 18px; font-weight: 750; letter-spacing: -.01em; }
.demo-ticks { display: flex; flex-direction: column; gap: 4px; margin: 10px 0 0; padding: 0; list-style: none; font-size: 13px; }
.demo-ticks li { display: flex; align-items: center; gap: 7px; }
.demo-ticks .icon { width: 15px; height: 15px; padding: 2px; border-radius: 50%; background: var(--success-soft); color: var(--success); stroke-width: 3; }
.demo-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.demo-watch, .demo-view { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: 8px; font-size: 13px; font-weight: 650; white-space: nowrap; }
.demo-watch { background: var(--text); color: #fff; }
.demo-watch svg { width: 10px; height: 10px; fill: currentColor; }
.demo-view { border: 1px solid var(--border-strong); color: var(--text); }
.demo-float { position: absolute; bottom: 0; left: -24px; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); box-shadow: 0 16px 32px -16px rgba(30, 27, 75, .35); font-size: 13px; font-weight: 650; white-space: nowrap; }
.demo-float-count { color: var(--text-muted); font-weight: 500; }

/* ---------- what you get + three steps ---------- */
.home-section { padding: var(--gap) 0; border-top: 1px solid var(--border); background: var(--surface-muted); }
.section-title-home { margin-bottom: 24px; font-size: clamp(26px, 3vw, 34px); font-weight: 720; line-height: 1.15; letter-spacing: -.025em; text-align: center; }

.tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tile { display: flex; align-items: flex-start; gap: 16px; padding: 24px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow-sm); }
.tile-icon { display: grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 12px; background: var(--primary-soft); color: var(--primary); }
.tile-icon-live { background: #fff1f2; color: var(--live); }
.tile h3 { font-size: 18px; font-weight: 680; letter-spacing: -.01em; }
.tile p { margin-top: 4px; color: #4b5563; line-height: 1.55; }

/* The steps and the closing button share one band. */
.start { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 28px 32px; margin-top: 16px; padding: 36px 40px; border-radius: 20px; background: radial-gradient(600px 300px at 10% 0%, rgba(255, 255, 255, .14), transparent 70%), linear-gradient(135deg, #4338ca 0%, #4f46e5 55%, #6d28d9 100%); color: #fff; box-shadow: 0 24px 48px -28px rgba(67, 56, 202, .7); }
.start-head h2 { font-size: clamp(24px, 2.6vw, 30px); font-weight: 720; letter-spacing: -.02em; }
.start-head p { margin-top: 4px; color: #e0e7ff; }
.start-cta { grid-column: 2; grid-row: 1; }
.start .btn-light:focus-visible { outline-color: rgba(255, 255, 255, .8); }
.home-steps { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.home-steps li { display: flex; align-items: flex-start; gap: 14px; padding: 18px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 14px; background: rgba(255, 255, 255, .08); }
.home-step-num { display: grid; place-items: center; width: 32px; height: 32px; flex: none; border-radius: 50%; background: #fff; color: var(--primary-hover); font-size: 15px; font-weight: 750; }
.home-steps h3 { font-size: 16px; font-weight: 650; line-height: 1.35; }
.home-steps p { margin-top: 2px; color: #e0e7ff; font-size: 14px; line-height: 1.5; }

/* ---------- footer ---------- */
.home-foot { padding: 24px 0; border-top: 1px solid var(--border); }
.home-foot-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.home-foot .brand { color: var(--text-muted); font-size: 14px; font-weight: 650; }
.home-foot .brand-mark { width: 26px; height: 26px; border-radius: 8px; }
.home-foot .brand-mark .icon { width: 14px; height: 14px; }
.home-foot-links { display: flex; gap: 24px; font-size: 14px; font-weight: 600; }
.home-foot-links a { color: var(--text-muted); }
.home-foot-links a:hover { color: var(--text); text-decoration: none; }

/* ---------- smaller screens ---------- */
@media (max-width: 960px) {
  .home { --gap: 48px; }
  .hero { padding-top: 48px; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .hero h1 { max-width: 14ch; }
  .hero-visual { width: 100%; max-width: 560px; }
  .demo-float { left: 16px; }
  .start { grid-template-columns: minmax(0, 1fr); padding: 28px; }
  .start-cta { grid-column: 1; grid-row: auto; justify-self: start; }
  .home-steps { grid-template-columns: minmax(0, 1fr); gap: 10px; }
}
@media (max-width: 640px) {
  .home { --gap: 40px; }
  .home-wrap { padding: 0 16px; }
  .home-top-inner { height: 60px; }
  .home .home-top .brand { font-size: 15px; }
  .home-top-actions .btn { height: 36px; padding: 0 12px; font-size: 14px; }
  .hero { padding-top: 32px; }
  .hero-lead { margin-top: 16px; }
  .hero-actions { margin-top: 24px; }
  .hero-actions .btn { flex: 1 1 100%; }
  .trust { margin-top: 16px; }
  .demo-body { padding: 14px; }
  .demo-product { grid-template-columns: 96px minmax(0, 1fr); gap: 12px; padding: 10px; }
  .demo-photo { min-height: 112px; }
  .demo-tabs span:not(.is-on) { display: none; }
  .section-title-home { margin-bottom: 20px; }
  .tiles { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .tile { padding: 20px; }
  .start { gap: 20px; padding: 24px 20px; border-radius: 18px; }
  .home-steps li { padding: 14px; }
  .start-cta { width: 100%; }
  .home-foot-inner { flex-direction: column; align-items: flex-start; gap: 12px; }
}
/* Phones: the hero's own button is right below, so the top bar keeps just Sign in. */
@media (max-width: 480px) {
  .home-top-actions .btn-primary { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .badge-live::before { animation: none; }
}
