/* Elsa product page (/elsa/). Uses styles.css for header, footer, fonts, buttons and the voice popup. */

/* ---------- Hero ---------- */
.ep-hero {
  padding: 150px 0 90px;
  color: #fff;
  background:
    radial-gradient(70% 60% at 85% 70%, rgba(255, 216, 107, 0.16), rgba(255, 216, 107, 0) 70%),
    linear-gradient(180deg, #1d1f42 0%, #11112f 100%);
}
.ep-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 56px;
}
.ep-hero .eyebrow {
  color: rgba(255, 255, 255, 0.92);
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(17, 17, 47, 0.45);
  font-weight: 650;
}
.ep-hero .eyebrow span {
  box-shadow: 0 0 0 3px rgba(20, 184, 111, 0.22), 0 0 10px rgba(20, 184, 111, 0.55);
}
.ep-hero h1 {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(44px, 6vw, 76px);
  line-height: 0.98;
  letter-spacing: -0.015em;
}
.ep-lead {
  max-width: 560px;
  margin: 24px 0 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 19px;
  line-height: 1.55;
}
.ep-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 22px;
  margin-top: 30px;
}
.ep-hero-actions .voice-open { margin-top: 0; }
.ep-ghost {
  color: #fff;
  font-weight: 700;
  border-bottom: 2px solid rgba(255, 255, 255, 0.6);
}
.ep-ghost:hover { border-color: var(--yellow); }
.ep-hand {
  margin: 14px 0 0;
  color: var(--yellow);
  font-family: var(--hand);
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
}

/* Example summary card */
.ep-summary {
  margin: 0;
  padding: 24px;
  color: var(--ink);
  border-radius: 16px;
  background: var(--paper);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) rotate(1deg);
  transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.ep-summary-tag {
  display: inline-block;
  margin: 0 0 10px;
  padding: 4px 10px;
  color: var(--brand-dark);
  border-radius: 999px;
  background: var(--soft-green);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.ep-summary-title {
  margin: 0 0 12px;
  font-family: var(--display);
  font-size: 22px;
  font-weight: 800;
}
.ep-summary dl { margin: 0; }
.ep-summary dl div {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 10px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
  font-size: 15px;
}
.ep-summary dt { color: var(--muted); font-weight: 600; }
.ep-summary dd { margin: 0; font-weight: 600; }
.ep-summary-next {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: var(--soft-green);
  font-size: 15px;
  font-weight: 700;
}
.ep-summary figcaption {
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
}

/* ---------- Sections ---------- */
.ep-section { padding: 90px 0; }
.ep-band .ep-section { padding: 90px 0; }
.ep-band { background: var(--soft); }
.ep-section h2 {
  max-width: 760px;
  margin: 0;
  font-family: var(--display);
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.02;
  letter-spacing: -0.01em;
}
.ep-section h3 {
  margin: 0;
  font-family: var(--display);
  font-size: 21px;
  line-height: 1.15;
}
.ep-section p { line-height: 1.55; }
.ep-intro {
  max-width: 620px;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 18px;
}

/* How it works */
.ep-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin: 40px 0 0;
  padding: 0;
  list-style: none;
}
.ep-steps li {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}
.ep-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
  color: #fff;
  border-radius: 50%;
  background: var(--ink);
  font-weight: 800;
}
.ep-steps p { margin: 8px 0 0; color: var(--muted); font-size: 15px; }

/* Who it's for */
.ep-trades {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 36px;
}
.ep-trade {
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}
.ep-trade h3 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  font-size: 19px;
}
.ep-trade-icon {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: var(--ink);
  border-radius: 12px;
  background: var(--soft);
}
.ep-trade > p { margin: 12px 0 0; color: var(--muted); font-size: 15px; }
.ep-trade .ep-asks {
  margin: 14px 0 6px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.ep-trade ul { margin: 0; padding: 0; list-style: none; }
.ep-cans li {
  position: relative;
  padding: 3px 0 3px 24px;
  font-size: 15px;
}
.ep-cans li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 3px;
  color: var(--brand-dark);
  font-weight: 800;
}
.ep-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ep-chips li {
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--soft);
  font-size: 13px;
  font-weight: 600;
}
.ep-chips .ep-more { padding: 4px 12px; color: var(--muted); background: transparent; border: 1px dashed var(--line); font-weight: 800; letter-spacing: 0.1em; }
.ep-trade-note { margin: 26px 0 0; color: var(--muted); }

/* Pricing */
.ep-pricing {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 440px);
  align-items: center;
  gap: 56px;
}
.ep-pricing-copy p:not(.kicker) { max-width: 480px; margin: 18px 0 0; color: var(--muted); font-size: 18px; }
.ep-plan {
  padding: 32px;
  color: #fff;
  border-radius: 22px;
  background: var(--ink);
  box-shadow: 0 30px 70px rgba(17, 17, 47, 0.25);
}
.ep-plan-name {
  margin: 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.ep-price { margin: 8px 0 0; font-family: var(--display); }
.ep-price strong { font-size: 64px; line-height: 1; }
.ep-price span { color: rgba(255, 255, 255, 0.75); font-size: 20px; }
.ep-setup { margin: 4px 0 0; color: rgba(255, 255, 255, 0.75); font-size: 16px; }
.ep-plan ul { margin: 22px 0 0; padding: 0; list-style: none; }
.ep-plan li {
  position: relative;
  padding: 7px 0 7px 28px;
  font-size: 15px;
}
.ep-plan li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 7px;
  color: #fff;
  font-weight: 800;
}
.ep-plan-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 22px;
  padding: 15px 20px;
  color: var(--ink);
  border-radius: 12px;
  background: var(--yellow);
  font-size: 17px;
  font-weight: 800;
}
.ep-plan-cta:hover { background: #fff; }
.ep-addon {
  margin: 18px 0 0;
  padding-top: 16px;
  color: rgba(255, 255, 255, 0.8);
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 14px;
  line-height: 1.5;
}
.ep-addon strong { color: #fff; }
.ep-fine { margin: 8px 0 0; color: rgba(255, 255, 255, 0.55); font-size: 13px; }

/* Free demo */
.ep-demo { padding: 90px 0; text-align: center; }
.ep-demo h2 {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(32px, 4.4vw, 52px);
  line-height: 1.02;
}
.ep-demo-inner > p { max-width: 560px; margin: 14px auto 26px; color: var(--muted); font-size: 18px; line-height: 1.55; }
.ep-demo .button {
  min-height: 54px;
  padding: 0 28px;
  gap: 8px;
  border: 0;
  font-size: 17px;
}
.ep-demo .ep-demo-note { margin: 16px auto 0; color: var(--ink-soft); font-size: 15px; }

/* ---------- Smaller screens ---------- */
@media (max-width: 980px) {
  .ep-hero { padding: 120px 0 64px; }
  .ep-hero-grid,
  .ep-pricing { grid-template-columns: 1fr; gap: 40px; }
  .ep-summary { max-width: 460px; }
  .ep-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ep-trades { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .ep-hero { padding: 110px 0 56px; }
  .ep-hero .eyebrow { font-size: 12px; }
  .ep-lead { font-size: 17px; }
  .ep-hero-actions .voice-open { width: 100%; }
  .ep-summary { padding: 20px; transform: none; }
  .ep-section,
  .ep-band .ep-section,
  .ep-demo { padding: 64px 0; }
  .ep-steps,
  .ep-trades { grid-template-columns: 1fr; }
  .ep-plan { padding: 26px 22px; }
  .ep-demo .cta-actions { flex-direction: column; }
  .ep-demo .cta-actions .hbx-elsa { order: -1; }
}

/* Screen-reader-only text */
.ep-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Business picker: phones only. Without JavaScript all cards show. */
.ep-trade-picks { display: none; }
@media (max-width: 680px) {
  .ep-js .ep-trade-picks {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
  }
  .ep-trade-pick {
    min-height: 40px;
    padding: 8px 14px;
    color: var(--ink);
    font: inherit;
    font-size: 14px;
    font-weight: 650;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
  }
  .ep-trade-pick[aria-pressed="true"] { color: #fff; border-color: var(--ink); background: var(--ink); }
  .ep-trade-pick:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }
  .ep-js .ep-trades { margin-top: 16px; }
  .ep-js .ep-trade { display: none; }
  .ep-js .ep-trade.is-active { display: block; }
}

/* ================= Motion and depth (Fable's ideas, 17 Nov) =================
   Everything below is still and complete unless html.ep-motion is set,
   which only happens when the visitor hasn't asked for reduced motion. */

/* ---------- Hero: Elsa orb + hello ---------- */
.ep-stage { position: relative; }
.ep-elsa {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 22px 6px;
}
.ep-orb {
  position: relative;
  flex: none;
  width: 92px;
  height: 92px;
  perspective: 420px;
}
.ep-orb-core {
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 34% 28%, #fffbe8 0%, #ffe08a 22%, #f5c451 52%, #c98a14 82%, #8a5a08 100%);
  box-shadow:
    0 0 28px rgba(245, 196, 81, 0.55),
    0 0 70px rgba(245, 196, 81, 0.25),
    inset -8px -10px 18px rgba(90, 50, 0, 0.35);
  overflow: hidden;
}
/* soft light moving inside the sphere */
.ep-orb-core::after {
  content: "";
  position: absolute;
  inset: -20%;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(255, 255, 255, 0) 0deg, rgba(255, 255, 255, 0.45) 60deg, rgba(255, 255, 255, 0) 140deg, rgba(255, 240, 200, 0.3) 230deg, rgba(255, 255, 255, 0) 320deg);
  filter: blur(6px);
  mix-blend-mode: soft-light;
}
/* two rings orbiting in real 3D */
.ep-orb-ring {
  position: absolute;
  inset: 0;
  border: 1.5px solid rgba(255, 216, 115, 0.55);
  border-radius: 50%;
  transform-style: preserve-3d;
}
.ep-orb-ring.r1 { transform: rotateX(72deg) rotateZ(0deg); }
.ep-orb-ring.r2 { inset: 4px; border-color: rgba(108, 139, 255, 0.45); transform: rotateY(68deg) rotateZ(0deg); }

.ep-hello-line {
  margin: 0;
  color: var(--yellow);
  font-family: var(--hand);
  font-size: 30px;
  font-weight: 600;
  line-height: 1;
}
.ep-status {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
  font-weight: 600;
}
.ep-status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 3px rgba(20, 184, 111, 0.25);
}

/* Reassurance row under the hero buttons */
.ep-assure {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
  color: rgba(255, 255, 255, 0.85);
  font-size: 15px;
  font-weight: 600;
}
.ep-assure li { display: inline-flex; align-items: center; gap: 7px; }
.ep-assure li::before {
  content: "\2713";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  color: var(--ink);
  border-radius: 50%;
  background: var(--brand);
  font-size: 11px;
  font-weight: 800;
}

/* ---------- Final demo section: dark navy, bookends the hero ---------- */
.ep-demo {
  color: #fff;
  background:
    radial-gradient(60% 80% at 50% 0%, rgba(245, 196, 81, 0.14), rgba(245, 196, 81, 0) 70%),
    linear-gradient(180deg, #11112f 0%, #1d1f42 100%);
}
.ep-demo-inner > p { color: rgba(255, 255, 255, 0.78); }
.ep-demo .ep-demo-note { color: rgba(255, 255, 255, 0.72); }
.ep-demo .hbx-email { color: var(--ink); background: #fff; box-shadow: none; }
.ep-demo .hbx-elsa { color: var(--ink); background: var(--yellow); box-shadow: 0 14px 30px rgba(245, 196, 81, 0.3); }
.ep-demo .hbx-elsa:hover { background: #fff; }
.ep-demo + .site-footer,
main + .site-footer { border-top: 1px solid rgba(255, 255, 255, 0.08); }

/* ---------- Desktop hover depth (works without motion too, it's user-driven) ---------- */
@media (hover: hover) and (pointer: fine) {
  .ep-trade,
  .ep-plan { transition: transform 0.25s ease, box-shadow 0.25s ease; }
  .ep-trade:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(20, 22, 46, 0.1);
  }
  .ep-trade-icon { transition: background 0.25s ease, color 0.25s ease; }
  .ep-trade:hover .ep-trade-icon { color: #fff; background: var(--brand-dark); }
  .ep-plan:hover,
  .ep-motion .ep-plan.ep-reveal.is-in:hover {
    transform: translateY(-6px);
    box-shadow: 0 40px 80px rgba(17, 17, 47, 0.32);
  }
}

/* ================= Only with motion allowed ================= */

/* Orb: slow breathing, rings orbit, faster while talking */
.ep-motion .ep-orb-core { animation: ep-breathe 4.5s ease-in-out infinite; }
.ep-motion .ep-orb-core::after { animation: ep-spin 9s linear infinite; }
.ep-motion .ep-orb-ring.r1 { animation: ep-ring1 12s linear infinite; }
.ep-motion .ep-orb-ring.r2 { animation: ep-ring2 16s linear infinite; }
.ep-motion .ep-stage.is-talking .ep-orb-core { animation-duration: 1.1s; }
.ep-motion .ep-stage.is-talking .ep-orb-ring.r1 { animation-duration: 4s; }
.ep-motion .ep-stage.is-talking .ep-orb-ring.r2 { animation-duration: 5s; }
.ep-motion .ep-stage.is-talking .ep-status-dot { animation: ep-blink 0.9s ease-in-out infinite; background: var(--yellow); box-shadow: 0 0 0 3px rgba(255, 216, 107, 0.25); }
@keyframes ep-breathe { 50% { transform: scale(1.06); box-shadow: 0 0 40px rgba(245, 196, 81, 0.7), 0 0 90px rgba(245, 196, 81, 0.3), inset -8px -10px 18px rgba(90, 50, 0, 0.35); } }
@keyframes ep-spin { to { transform: rotate(360deg); } }
@keyframes ep-ring1 { from { transform: rotateX(72deg) rotateZ(0deg); } to { transform: rotateX(72deg) rotateZ(360deg); } }
@keyframes ep-ring2 { from { transform: rotateY(68deg) rotateZ(0deg); } to { transform: rotateY(68deg) rotateZ(-360deg); } }
@keyframes ep-blink { 50% { opacity: 0.35; } }

/* Summary card fills in line by line */
.ep-motion .ep-summary dd,
.ep-motion .ep-summary-next {
  opacity: 0;
  transform: translateX(-10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.ep-motion .ep-summary dl > div.is-filled dd,
.ep-motion .ep-summary-next.is-filled { opacity: 1; transform: none; }
.ep-motion .ep-summary-next.is-filled { animation: ep-flash 1.2s ease 0.3s; }
@keyframes ep-flash { 40% { box-shadow: 0 0 0 6px rgba(20, 184, 111, 0.25); } }

/* Sections rise in */
.ep-motion .ep-reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease var(--d, 0ms), transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) var(--d, 0ms);
}
.ep-motion .ep-reveal.is-in { opacity: 1; transform: none; }

/* How it works: a line draws across the four steps (desktop, 4 columns) */
@media (min-width: 981px) {
  .ep-steps { position: relative; }
  .ep-steps li { position: relative; z-index: 1; }
  .ep-steps::before {
    content: "";
    position: absolute;
    left: 6%;
    right: 6%;
    top: 39px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--brand), var(--yellow));
  }
  .ep-motion .ep-steps::before { transform: scaleX(0); transform-origin: left; transition: transform 1.1s ease 0.2s; }
  .ep-motion .ep-steps.is-in::before { transform: scaleX(1); }
}

/* Pricing card: one light sweep when it first appears */
.ep-plan { position: relative; overflow: hidden; }
.ep-plan::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -60%;
  width: 45%;
  background: linear-gradient(100deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.14) 50%, rgba(255, 255, 255, 0) 100%);
  transform: skewX(-12deg);
  pointer-events: none;
  opacity: 0;
}
.ep-motion .ep-plan.is-in::after { animation: ep-sweep 1.4s ease 0.5s 1; }
@keyframes ep-sweep { 0% { left: -60%; opacity: 1; } 100% { left: 120%; opacity: 1; } }

/* Business cards on phones: picked card slides in, chips pop one by one */
@media (max-width: 680px) {
  .ep-motion .ep-trade.is-active { animation: ep-card-in 0.4s cubic-bezier(0.2, 0.7, 0.2, 1); }
  .ep-motion .ep-trade.is-active .ep-chips li { animation: ep-pop 0.35s cubic-bezier(0.3, 1.4, 0.5, 1) both; }
  .ep-motion .ep-trade.is-active .ep-chips li:nth-child(1) { animation-delay: 0.15s; }
  .ep-motion .ep-trade.is-active .ep-chips li:nth-child(2) { animation-delay: 0.22s; }
  .ep-motion .ep-trade.is-active .ep-chips li:nth-child(3) { animation-delay: 0.29s; }
  .ep-motion .ep-trade.is-active .ep-chips li:nth-child(4) { animation-delay: 0.36s; }
  .ep-motion .ep-trade.is-active .ep-chips li:nth-child(5) { animation-delay: 0.43s; }
}
@keyframes ep-card-in { from { opacity: 0; transform: translateX(24px); } }
@keyframes ep-pop { from { opacity: 0; transform: scale(0.6); } }

/* ---------- Hero sizes on smaller screens ---------- */
@media (max-width: 980px) {
  .ep-elsa { margin-left: 0; }
}
@media (max-width: 680px) {
  .ep-orb { width: 72px; height: 72px; }
  .ep-orb-core { inset: 6px; }
  .ep-hello-line { font-size: 26px; }
  .ep-assure { font-size: 14px; gap: 8px 14px; }
}

/* Reduced motion: belt and braces, nothing moves even on hover */
@media (prefers-reduced-motion: reduce) {
  .ep-summary { transition: none; }
  .ep-trade:hover,
  .ep-plan:hover { transform: none; }
}

/* ---------- FAQ (after pricing) ---------- */
.ep-faq .kicker { margin-bottom: 10px; }
.ep-faq-list {
  max-width: 820px;
  margin-top: 34px;
  border-top: 1px solid rgba(17, 17, 47, 0.12);
}
.ep-faq-item { border-bottom: 1px solid rgba(17, 17, 47, 0.12); }
.ep-faq-item summary {
  position: relative;
  padding: 22px 48px 22px 0;
  font-family: var(--display);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}
.ep-faq-item summary::-webkit-details-marker { display: none; }
.ep-faq-item summary::after {
  content: "+";
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 26px;
  font-weight: 500;
  color: var(--ink);
}
.ep-faq-item[open] summary::after { content: "\2212"; }
.ep-faq-item summary:focus-visible { outline: 3px solid var(--yellow); outline-offset: 4px; border-radius: 4px; }
.ep-faq-item p {
  max-width: 680px;
  margin: 0 0 24px;
  color: var(--ink-soft);
  font-size: 17px;
  line-height: 1.6;
}
@media (max-width: 640px) {
  .ep-faq-item summary { font-size: 18px; padding: 18px 40px 18px 0; }
  .ep-faq-item p { font-size: 16px; }
}
